Pass -rpath and -version-info options to libtool.
[libsigsegv/ericb.git] / configure
blob5d3a089d9116ee553f903c0af16067bff6b50b20
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.63.
5 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
6 # 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
9 ## --------------------- ##
10 ## M4sh Initialization. ##
11 ## --------------------- ##
13 # Be more Bourne compatible
14 DUALCASE=1; export DUALCASE # for MKS sh
15 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
16 emulate sh
17 NULLCMD=:
18 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
19 # is contrary to our usage. Disable this feature.
20 alias -g '${1+"$@"}'='"$@"'
21 setopt NO_GLOB_SUBST
22 else
23 case `(set -o) 2>/dev/null` in
24 *posix*) set -o posix ;;
25 esac
32 # PATH needs CR
33 # Avoid depending upon Character Ranges.
34 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
35 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
36 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
37 as_cr_digits='0123456789'
38 as_cr_alnum=$as_cr_Letters$as_cr_digits
40 as_nl='
42 export as_nl
43 # Printing a long string crashes Solaris 7 /usr/bin/printf.
44 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
45 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
46 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
47 if (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"
65 export as_echo_n_body
66 as_echo_n='sh -c $as_echo_n_body as_echo'
68 export as_echo_body
69 as_echo='sh -c $as_echo_body as_echo'
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=';'
81 # Support unset when possible.
82 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
83 as_unset=unset
84 else
85 as_unset=false
89 # IFS
90 # We need space, tab and new line, in precisely that order. Quoting is
91 # there to prevent editors from complaining about space-tab.
92 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
93 # splitting by setting IFS to empty value.)
94 IFS=" "" $as_nl"
96 # Find who we are. Look in the path if we contain no directory separator.
97 case $0 in
98 *[\\/]* ) as_myself=$0 ;;
99 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
100 for as_dir in $PATH
102 IFS=$as_save_IFS
103 test -z "$as_dir" && as_dir=.
104 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
105 done
106 IFS=$as_save_IFS
109 esac
110 # We did not find ourselves, most probably we were run as `sh COMMAND'
111 # in which case we are not to be found in the path.
112 if test "x$as_myself" = x; then
113 as_myself=$0
115 if test ! -f "$as_myself"; then
116 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
117 { (exit 1); exit 1; }
120 # Work around bugs in pre-3.0 UWIN ksh.
121 for as_var in ENV MAIL MAILPATH
122 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
123 done
124 PS1='$ '
125 PS2='> '
126 PS4='+ '
128 # NLS nuisances.
129 LC_ALL=C
130 export LC_ALL
131 LANGUAGE=C
132 export LANGUAGE
134 # Required to use basename.
135 if expr a : '\(a\)' >/dev/null 2>&1 &&
136 test "X`expr 00001 : '.*\(...\)'`" = X001; then
137 as_expr=expr
138 else
139 as_expr=false
142 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
143 as_basename=basename
144 else
145 as_basename=false
149 # Name of the executable.
150 as_me=`$as_basename -- "$0" ||
151 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
152 X"$0" : 'X\(//\)$' \| \
153 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
154 $as_echo X/"$0" |
155 sed '/^.*\/\([^/][^/]*\)\/*$/{
156 s//\1/
159 /^X\/\(\/\/\)$/{
160 s//\1/
163 /^X\/\(\/\).*/{
164 s//\1/
167 s/.*/./; q'`
169 # CDPATH.
170 $as_unset CDPATH
173 if test "x$CONFIG_SHELL" = x; then
174 if (eval ":") 2>/dev/null; then
175 as_have_required=yes
176 else
177 as_have_required=no
180 if test $as_have_required = yes && (eval ":
181 (as_func_return () {
182 (exit \$1)
184 as_func_success () {
185 as_func_return 0
187 as_func_failure () {
188 as_func_return 1
190 as_func_ret_success () {
191 return 0
193 as_func_ret_failure () {
194 return 1
197 exitcode=0
198 if as_func_success; then
200 else
201 exitcode=1
202 echo as_func_success failed.
205 if as_func_failure; then
206 exitcode=1
207 echo as_func_failure succeeded.
210 if as_func_ret_success; then
212 else
213 exitcode=1
214 echo as_func_ret_success failed.
217 if as_func_ret_failure; then
218 exitcode=1
219 echo as_func_ret_failure succeeded.
222 if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
224 else
225 exitcode=1
226 echo positional parameters were not saved.
229 test \$exitcode = 0) || { (exit 1); exit 1; }
232 as_lineno_1=\$LINENO
233 as_lineno_2=\$LINENO
234 test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" &&
235 test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; }
236 ") 2> /dev/null; then
238 else
239 as_candidate_shells=
240 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
241 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
243 IFS=$as_save_IFS
244 test -z "$as_dir" && as_dir=.
245 case $as_dir in
247 for as_base in sh bash ksh sh5; do
248 as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
249 done;;
250 esac
251 done
252 IFS=$as_save_IFS
255 for as_shell in $as_candidate_shells $SHELL; do
256 # Try only shells that exist, to save several forks.
257 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
258 { ("$as_shell") 2> /dev/null <<\_ASEOF
259 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
260 emulate sh
261 NULLCMD=:
262 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
263 # is contrary to our usage. Disable this feature.
264 alias -g '${1+"$@"}'='"$@"'
265 setopt NO_GLOB_SUBST
266 else
267 case `(set -o) 2>/dev/null` in
268 *posix*) set -o posix ;;
269 esac
275 _ASEOF
276 }; then
277 CONFIG_SHELL=$as_shell
278 as_have_required=yes
279 if { "$as_shell" 2> /dev/null <<\_ASEOF
280 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
281 emulate sh
282 NULLCMD=:
283 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
284 # is contrary to our usage. Disable this feature.
285 alias -g '${1+"$@"}'='"$@"'
286 setopt NO_GLOB_SUBST
287 else
288 case `(set -o) 2>/dev/null` in
289 *posix*) set -o posix ;;
290 esac
296 (as_func_return () {
297 (exit $1)
299 as_func_success () {
300 as_func_return 0
302 as_func_failure () {
303 as_func_return 1
305 as_func_ret_success () {
306 return 0
308 as_func_ret_failure () {
309 return 1
312 exitcode=0
313 if as_func_success; then
315 else
316 exitcode=1
317 echo as_func_success failed.
320 if as_func_failure; then
321 exitcode=1
322 echo as_func_failure succeeded.
325 if as_func_ret_success; then
327 else
328 exitcode=1
329 echo as_func_ret_success failed.
332 if as_func_ret_failure; then
333 exitcode=1
334 echo as_func_ret_failure succeeded.
337 if ( set x; as_func_ret_success y && test x = "$1" ); then
339 else
340 exitcode=1
341 echo positional parameters were not saved.
344 test $exitcode = 0) || { (exit 1); exit 1; }
347 as_lineno_1=$LINENO
348 as_lineno_2=$LINENO
349 test "x$as_lineno_1" != "x$as_lineno_2" &&
350 test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; }
352 _ASEOF
353 }; then
354 break
359 done
361 if test "x$CONFIG_SHELL" != x; then
362 for as_var in BASH_ENV ENV
363 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
364 done
365 export CONFIG_SHELL
366 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
370 if test $as_have_required = no; then
371 echo This script requires a shell more modern than all the
372 echo shells that I found on your system. Please install a
373 echo modern shell, or manually run the script under such a
374 echo shell if you do have one.
375 { (exit 1); exit 1; }
385 (eval "as_func_return () {
386 (exit \$1)
388 as_func_success () {
389 as_func_return 0
391 as_func_failure () {
392 as_func_return 1
394 as_func_ret_success () {
395 return 0
397 as_func_ret_failure () {
398 return 1
401 exitcode=0
402 if as_func_success; then
404 else
405 exitcode=1
406 echo as_func_success failed.
409 if as_func_failure; then
410 exitcode=1
411 echo as_func_failure succeeded.
414 if as_func_ret_success; then
416 else
417 exitcode=1
418 echo as_func_ret_success failed.
421 if as_func_ret_failure; then
422 exitcode=1
423 echo as_func_ret_failure succeeded.
426 if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
428 else
429 exitcode=1
430 echo positional parameters were not saved.
433 test \$exitcode = 0") || {
434 echo No shell found that supports shell functions.
435 echo Please tell bug-autoconf@gnu.org about your system,
436 echo including any error possibly output before this message.
437 echo This can help us improve future autoconf versions.
438 echo Configuration will now proceed without shell functions.
443 as_lineno_1=$LINENO
444 as_lineno_2=$LINENO
445 test "x$as_lineno_1" != "x$as_lineno_2" &&
446 test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
448 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
449 # uniformly replaced by the line number. The first 'sed' inserts a
450 # line-number line after each line using $LINENO; the second 'sed'
451 # does the real work. The second script uses 'N' to pair each
452 # line-number line with the line containing $LINENO, and appends
453 # trailing '-' during substitution so that $LINENO is not a special
454 # case at line end.
455 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
456 # scripts with optimization help from Paolo Bonzini. Blame Lee
457 # E. McMahon (1931-1989) for sed's syntax. :-)
458 sed -n '
460 /[$]LINENO/=
461 ' <$as_myself |
462 sed '
463 s/[$]LINENO.*/&-/
464 t lineno
466 :lineno
468 :loop
469 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
470 t loop
471 s/-\n.*//
472 ' >$as_me.lineno &&
473 chmod +x "$as_me.lineno" ||
474 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
475 { (exit 1); exit 1; }; }
477 # Don't try to exec as it changes $[0], causing all sort of problems
478 # (the dirname of $[0] is not the place where we might find the
479 # original and so on. Autoconf is especially sensitive to this).
480 . "./$as_me.lineno"
481 # Exit status is that of the last command.
482 exit
486 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
487 as_dirname=dirname
488 else
489 as_dirname=false
492 ECHO_C= ECHO_N= ECHO_T=
493 case `echo -n x` in
494 -n*)
495 case `echo 'x\c'` in
496 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
497 *) ECHO_C='\c';;
498 esac;;
500 ECHO_N='-n';;
501 esac
502 if expr a : '\(a\)' >/dev/null 2>&1 &&
503 test "X`expr 00001 : '.*\(...\)'`" = X001; then
504 as_expr=expr
505 else
506 as_expr=false
509 rm -f conf$$ conf$$.exe conf$$.file
510 if test -d conf$$.dir; then
511 rm -f conf$$.dir/conf$$.file
512 else
513 rm -f conf$$.dir
514 mkdir conf$$.dir 2>/dev/null
516 if (echo >conf$$.file) 2>/dev/null; then
517 if ln -s conf$$.file conf$$ 2>/dev/null; then
518 as_ln_s='ln -s'
519 # ... but there are two gotchas:
520 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
521 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
522 # In both cases, we have to default to `cp -p'.
523 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
524 as_ln_s='cp -p'
525 elif ln conf$$.file conf$$ 2>/dev/null; then
526 as_ln_s=ln
527 else
528 as_ln_s='cp -p'
530 else
531 as_ln_s='cp -p'
533 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
534 rmdir conf$$.dir 2>/dev/null
536 if mkdir -p . 2>/dev/null; then
537 as_mkdir_p=:
538 else
539 test -d ./-p && rmdir ./-p
540 as_mkdir_p=false
543 if test -x / >/dev/null 2>&1; then
544 as_test_x='test -x'
545 else
546 if ls -dL / >/dev/null 2>&1; then
547 as_ls_L_option=L
548 else
549 as_ls_L_option=
551 as_test_x='
552 eval sh -c '\''
553 if test -d "$1"; then
554 test -d "$1/.";
555 else
556 case $1 in
557 -*)set "./$1";;
558 esac;
559 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
560 ???[sx]*):;;*)false;;esac;fi
561 '\'' sh
564 as_executable_p=$as_test_x
566 # Sed expression to map a string onto a valid CPP name.
567 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
569 # Sed expression to map a string onto a valid variable name.
570 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
575 # Check that we are running under the correct shell.
576 SHELL=${CONFIG_SHELL-/bin/sh}
578 case X$lt_ECHO in
579 X*--fallback-echo)
580 # Remove one level of quotation (which was required for Make).
581 ECHO=`echo "$lt_ECHO" | sed 's,\\\\\$\\$0,'$0','`
583 esac
585 ECHO=${lt_ECHO-echo}
586 if test "X$1" = X--no-reexec; then
587 # Discard the --no-reexec flag, and continue.
588 shift
589 elif test "X$1" = X--fallback-echo; then
590 # Avoid inline document here, it may be left over
592 elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then
593 # Yippee, $ECHO works!
595 else
596 # Restart under the correct shell.
597 exec $SHELL "$0" --no-reexec ${1+"$@"}
600 if test "X$1" = X--fallback-echo; then
601 # used as fallback echo
602 shift
603 cat <<_LT_EOF
605 _LT_EOF
606 exit 0
609 # The HP-UX ksh and POSIX shell print the target directory to stdout
610 # if CDPATH is set.
611 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
613 if test -z "$lt_ECHO"; then
614 if test "X${echo_test_string+set}" != Xset; then
615 # find a string as large as possible, as long as the shell can cope with it
616 for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do
617 # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
618 if { echo_test_string=`eval $cmd`; } 2>/dev/null &&
619 { test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null
620 then
621 break
623 done
626 if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
627 echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
628 test "X$echo_testing_string" = "X$echo_test_string"; then
630 else
631 # The Solaris, AIX, and Digital Unix default echo programs unquote
632 # backslashes. This makes it impossible to quote backslashes using
633 # echo "$something" | sed 's/\\/\\\\/g'
635 # So, first we look for a working echo in the user's PATH.
637 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
638 for dir in $PATH /usr/ucb; do
639 IFS="$lt_save_ifs"
640 if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
641 test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
642 echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
643 test "X$echo_testing_string" = "X$echo_test_string"; then
644 ECHO="$dir/echo"
645 break
647 done
648 IFS="$lt_save_ifs"
650 if test "X$ECHO" = Xecho; then
651 # We didn't find a better echo, so look for alternatives.
652 if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' &&
653 echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` &&
654 test "X$echo_testing_string" = "X$echo_test_string"; then
655 # This shell has a builtin print -r that does the trick.
656 ECHO='print -r'
657 elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } &&
658 test "X$CONFIG_SHELL" != X/bin/ksh; then
659 # If we have ksh, try running configure again with it.
660 ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
661 export ORIGINAL_CONFIG_SHELL
662 CONFIG_SHELL=/bin/ksh
663 export CONFIG_SHELL
664 exec $CONFIG_SHELL "$0" --no-reexec ${1+"$@"}
665 else
666 # Try using printf.
667 ECHO='printf %s\n'
668 if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
669 echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
670 test "X$echo_testing_string" = "X$echo_test_string"; then
671 # Cool, printf works
673 elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
674 test "X$echo_testing_string" = 'X\t' &&
675 echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
676 test "X$echo_testing_string" = "X$echo_test_string"; then
677 CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
678 export CONFIG_SHELL
679 SHELL="$CONFIG_SHELL"
680 export SHELL
681 ECHO="$CONFIG_SHELL $0 --fallback-echo"
682 elif echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
683 test "X$echo_testing_string" = 'X\t' &&
684 echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
685 test "X$echo_testing_string" = "X$echo_test_string"; then
686 ECHO="$CONFIG_SHELL $0 --fallback-echo"
687 else
688 # maybe with a smaller string...
689 prev=:
691 for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do
692 if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null
693 then
694 break
696 prev="$cmd"
697 done
699 if test "$prev" != 'sed 50q "$0"'; then
700 echo_test_string=`eval $prev`
701 export echo_test_string
702 exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "$0" ${1+"$@"}
703 else
704 # Oops. We lost completely, so just stick with echo.
705 ECHO=echo
713 # Copy echo and quote the copy suitably for passing to libtool from
714 # the Makefile, instead of quoting the original, which is used later.
715 lt_ECHO=$ECHO
716 if test "X$lt_ECHO" = "X$CONFIG_SHELL $0 --fallback-echo"; then
717 lt_ECHO="$CONFIG_SHELL \\\$\$0 --fallback-echo"
723 exec 7<&0 </dev/null 6>&1
725 # Name of the host.
726 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
727 # so uname gets run too.
728 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
731 # Initializations.
733 ac_default_prefix=/usr/local
734 ac_clean_files=
735 ac_config_libobj_dir=.
736 LIBOBJS=
737 cross_compiling=no
738 subdirs=
739 MFLAGS=
740 MAKEFLAGS=
741 SHELL=${CONFIG_SHELL-/bin/sh}
743 # Identity of this package.
744 PACKAGE_NAME=
745 PACKAGE_TARNAME=
746 PACKAGE_VERSION=
747 PACKAGE_STRING=
748 PACKAGE_BUGREPORT=
750 ac_unique_file="src/sigsegv.h.in"
751 # Factoring default headers for most tests.
752 ac_includes_default="\
753 #include <stdio.h>
754 #ifdef HAVE_SYS_TYPES_H
755 # include <sys/types.h>
756 #endif
757 #ifdef HAVE_SYS_STAT_H
758 # include <sys/stat.h>
759 #endif
760 #ifdef STDC_HEADERS
761 # include <stdlib.h>
762 # include <stddef.h>
763 #else
764 # ifdef HAVE_STDLIB_H
765 # include <stdlib.h>
766 # endif
767 #endif
768 #ifdef HAVE_STRING_H
769 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
770 # include <memory.h>
771 # endif
772 # include <string.h>
773 #endif
774 #ifdef HAVE_STRINGS_H
775 # include <strings.h>
776 #endif
777 #ifdef HAVE_INTTYPES_H
778 # include <inttypes.h>
779 #endif
780 #ifdef HAVE_STDINT_H
781 # include <stdint.h>
782 #endif
783 #ifdef HAVE_UNISTD_H
784 # include <unistd.h>
785 #endif"
787 ac_subst_vars='LTLIBOBJS
788 LIBOBJS
789 RELOCATABLE
790 CFG_HANDLER
791 CFG_LEAVE
792 HAVE_STACK_OVERFLOW_RECOVERY
793 CFG_STACKVMA
794 HAVE_SIGSEGV_RECOVERY
795 FAULT_CONTEXT_INCLUDE
796 FAULT_CONTEXT
797 OTOOL64
798 OTOOL
799 LIPO
800 NMEDIT
801 DSYMUTIL
802 lt_ECHO
803 RANLIB
805 OBJDUMP
806 LN_S
808 ac_ct_DUMPBIN
809 DUMPBIN
811 FGREP
812 EGREP
813 GREP
815 LIBTOOL
816 PLATFORM
817 host_os
818 host_vendor
819 host_cpu
820 host
821 build_os
822 build_vendor
823 build_cpu
824 build
826 am__fastdepCC_FALSE
827 am__fastdepCC_TRUE
828 CCDEPMODE
829 AMDEPBACKSLASH
830 AMDEP_FALSE
831 AMDEP_TRUE
832 am__quote
833 am__include
834 DEPDIR
835 OBJEXT
836 EXEEXT
837 ac_ct_CC
838 CPPFLAGS
839 LDFLAGS
840 CFLAGS
842 am__untar
843 am__tar
844 AMTAR
845 am__leading_dot
846 SET_MAKE
848 mkdir_p
849 MKDIR_P
850 INSTALL_STRIP_PROGRAM
851 STRIP
852 install_sh
853 MAKEINFO
854 AUTOHEADER
855 AUTOMAKE
856 AUTOCONF
857 ACLOCAL
858 VERSION
859 PACKAGE
860 CYGPATH_W
861 am__isrc
862 INSTALL_DATA
863 INSTALL_SCRIPT
864 INSTALL_PROGRAM
865 target_alias
866 host_alias
867 build_alias
868 LIBS
869 ECHO_T
870 ECHO_N
871 ECHO_C
872 DEFS
873 mandir
874 localedir
875 libdir
876 psdir
877 pdfdir
878 dvidir
879 htmldir
880 infodir
881 docdir
882 oldincludedir
883 includedir
884 localstatedir
885 sharedstatedir
886 sysconfdir
887 datadir
888 datarootdir
889 libexecdir
890 sbindir
891 bindir
892 program_transform_name
893 prefix
894 exec_prefix
895 PACKAGE_BUGREPORT
896 PACKAGE_STRING
897 PACKAGE_VERSION
898 PACKAGE_TARNAME
899 PACKAGE_NAME
900 PATH_SEPARATOR
901 SHELL'
902 ac_subst_files=''
903 ac_user_opts='
904 enable_option_checking
905 enable_dependency_tracking
906 enable_shared
907 enable_static
908 with_pic
909 enable_fast_install
910 with_gnu_ld
911 enable_libtool_lock
912 enable_relocatable
914 ac_precious_vars='build_alias
915 host_alias
916 target_alias
918 CFLAGS
919 LDFLAGS
920 LIBS
921 CPPFLAGS
922 CPP'
925 # Initialize some variables set by options.
926 ac_init_help=
927 ac_init_version=false
928 ac_unrecognized_opts=
929 ac_unrecognized_sep=
930 # The variables have the same names as the options, with
931 # dashes changed to underlines.
932 cache_file=/dev/null
933 exec_prefix=NONE
934 no_create=
935 no_recursion=
936 prefix=NONE
937 program_prefix=NONE
938 program_suffix=NONE
939 program_transform_name=s,x,x,
940 silent=
941 site=
942 srcdir=
943 verbose=
944 x_includes=NONE
945 x_libraries=NONE
947 # Installation directory options.
948 # These are left unexpanded so users can "make install exec_prefix=/foo"
949 # and all the variables that are supposed to be based on exec_prefix
950 # by default will actually change.
951 # Use braces instead of parens because sh, perl, etc. also accept them.
952 # (The list follows the same order as the GNU Coding Standards.)
953 bindir='${exec_prefix}/bin'
954 sbindir='${exec_prefix}/sbin'
955 libexecdir='${exec_prefix}/libexec'
956 datarootdir='${prefix}/share'
957 datadir='${datarootdir}'
958 sysconfdir='${prefix}/etc'
959 sharedstatedir='${prefix}/com'
960 localstatedir='${prefix}/var'
961 includedir='${prefix}/include'
962 oldincludedir='/usr/include'
963 docdir='${datarootdir}/doc/${PACKAGE}'
964 infodir='${datarootdir}/info'
965 htmldir='${docdir}'
966 dvidir='${docdir}'
967 pdfdir='${docdir}'
968 psdir='${docdir}'
969 libdir='${exec_prefix}/lib'
970 localedir='${datarootdir}/locale'
971 mandir='${datarootdir}/man'
973 ac_prev=
974 ac_dashdash=
975 for ac_option
977 # If the previous option needs an argument, assign it.
978 if test -n "$ac_prev"; then
979 eval $ac_prev=\$ac_option
980 ac_prev=
981 continue
984 case $ac_option in
985 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
986 *) ac_optarg=yes ;;
987 esac
989 # Accept the important Cygnus configure options, so we can diagnose typos.
991 case $ac_dashdash$ac_option in
993 ac_dashdash=yes ;;
995 -bindir | --bindir | --bindi | --bind | --bin | --bi)
996 ac_prev=bindir ;;
997 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
998 bindir=$ac_optarg ;;
1000 -build | --build | --buil | --bui | --bu)
1001 ac_prev=build_alias ;;
1002 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1003 build_alias=$ac_optarg ;;
1005 -cache-file | --cache-file | --cache-fil | --cache-fi \
1006 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1007 ac_prev=cache_file ;;
1008 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1009 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1010 cache_file=$ac_optarg ;;
1012 --config-cache | -C)
1013 cache_file=config.cache ;;
1015 -datadir | --datadir | --datadi | --datad)
1016 ac_prev=datadir ;;
1017 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1018 datadir=$ac_optarg ;;
1020 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1021 | --dataroo | --dataro | --datar)
1022 ac_prev=datarootdir ;;
1023 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1024 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1025 datarootdir=$ac_optarg ;;
1027 -disable-* | --disable-*)
1028 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1029 # Reject names that are not valid shell variable names.
1030 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1031 { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
1032 { (exit 1); exit 1; }; }
1033 ac_useropt_orig=$ac_useropt
1034 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1035 case $ac_user_opts in
1037 "enable_$ac_useropt"
1038 "*) ;;
1039 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1040 ac_unrecognized_sep=', ';;
1041 esac
1042 eval enable_$ac_useropt=no ;;
1044 -docdir | --docdir | --docdi | --doc | --do)
1045 ac_prev=docdir ;;
1046 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1047 docdir=$ac_optarg ;;
1049 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1050 ac_prev=dvidir ;;
1051 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1052 dvidir=$ac_optarg ;;
1054 -enable-* | --enable-*)
1055 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1056 # Reject names that are not valid shell variable names.
1057 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1058 { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
1059 { (exit 1); exit 1; }; }
1060 ac_useropt_orig=$ac_useropt
1061 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1062 case $ac_user_opts in
1064 "enable_$ac_useropt"
1065 "*) ;;
1066 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1067 ac_unrecognized_sep=', ';;
1068 esac
1069 eval enable_$ac_useropt=\$ac_optarg ;;
1071 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1072 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1073 | --exec | --exe | --ex)
1074 ac_prev=exec_prefix ;;
1075 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1076 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1077 | --exec=* | --exe=* | --ex=*)
1078 exec_prefix=$ac_optarg ;;
1080 -gas | --gas | --ga | --g)
1081 # Obsolete; use --with-gas.
1082 with_gas=yes ;;
1084 -help | --help | --hel | --he | -h)
1085 ac_init_help=long ;;
1086 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1087 ac_init_help=recursive ;;
1088 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1089 ac_init_help=short ;;
1091 -host | --host | --hos | --ho)
1092 ac_prev=host_alias ;;
1093 -host=* | --host=* | --hos=* | --ho=*)
1094 host_alias=$ac_optarg ;;
1096 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1097 ac_prev=htmldir ;;
1098 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1099 | --ht=*)
1100 htmldir=$ac_optarg ;;
1102 -includedir | --includedir | --includedi | --included | --include \
1103 | --includ | --inclu | --incl | --inc)
1104 ac_prev=includedir ;;
1105 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1106 | --includ=* | --inclu=* | --incl=* | --inc=*)
1107 includedir=$ac_optarg ;;
1109 -infodir | --infodir | --infodi | --infod | --info | --inf)
1110 ac_prev=infodir ;;
1111 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1112 infodir=$ac_optarg ;;
1114 -libdir | --libdir | --libdi | --libd)
1115 ac_prev=libdir ;;
1116 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1117 libdir=$ac_optarg ;;
1119 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1120 | --libexe | --libex | --libe)
1121 ac_prev=libexecdir ;;
1122 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1123 | --libexe=* | --libex=* | --libe=*)
1124 libexecdir=$ac_optarg ;;
1126 -localedir | --localedir | --localedi | --localed | --locale)
1127 ac_prev=localedir ;;
1128 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1129 localedir=$ac_optarg ;;
1131 -localstatedir | --localstatedir | --localstatedi | --localstated \
1132 | --localstate | --localstat | --localsta | --localst | --locals)
1133 ac_prev=localstatedir ;;
1134 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1135 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1136 localstatedir=$ac_optarg ;;
1138 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1139 ac_prev=mandir ;;
1140 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1141 mandir=$ac_optarg ;;
1143 -nfp | --nfp | --nf)
1144 # Obsolete; use --without-fp.
1145 with_fp=no ;;
1147 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1148 | --no-cr | --no-c | -n)
1149 no_create=yes ;;
1151 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1152 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1153 no_recursion=yes ;;
1155 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1156 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1157 | --oldin | --oldi | --old | --ol | --o)
1158 ac_prev=oldincludedir ;;
1159 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1160 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1161 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1162 oldincludedir=$ac_optarg ;;
1164 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1165 ac_prev=prefix ;;
1166 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1167 prefix=$ac_optarg ;;
1169 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1170 | --program-pre | --program-pr | --program-p)
1171 ac_prev=program_prefix ;;
1172 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1173 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1174 program_prefix=$ac_optarg ;;
1176 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1177 | --program-suf | --program-su | --program-s)
1178 ac_prev=program_suffix ;;
1179 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1180 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1181 program_suffix=$ac_optarg ;;
1183 -program-transform-name | --program-transform-name \
1184 | --program-transform-nam | --program-transform-na \
1185 | --program-transform-n | --program-transform- \
1186 | --program-transform | --program-transfor \
1187 | --program-transfo | --program-transf \
1188 | --program-trans | --program-tran \
1189 | --progr-tra | --program-tr | --program-t)
1190 ac_prev=program_transform_name ;;
1191 -program-transform-name=* | --program-transform-name=* \
1192 | --program-transform-nam=* | --program-transform-na=* \
1193 | --program-transform-n=* | --program-transform-=* \
1194 | --program-transform=* | --program-transfor=* \
1195 | --program-transfo=* | --program-transf=* \
1196 | --program-trans=* | --program-tran=* \
1197 | --progr-tra=* | --program-tr=* | --program-t=*)
1198 program_transform_name=$ac_optarg ;;
1200 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1201 ac_prev=pdfdir ;;
1202 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1203 pdfdir=$ac_optarg ;;
1205 -psdir | --psdir | --psdi | --psd | --ps)
1206 ac_prev=psdir ;;
1207 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1208 psdir=$ac_optarg ;;
1210 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1211 | -silent | --silent | --silen | --sile | --sil)
1212 silent=yes ;;
1214 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1215 ac_prev=sbindir ;;
1216 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1217 | --sbi=* | --sb=*)
1218 sbindir=$ac_optarg ;;
1220 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1221 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1222 | --sharedst | --shareds | --shared | --share | --shar \
1223 | --sha | --sh)
1224 ac_prev=sharedstatedir ;;
1225 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1226 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1227 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1228 | --sha=* | --sh=*)
1229 sharedstatedir=$ac_optarg ;;
1231 -site | --site | --sit)
1232 ac_prev=site ;;
1233 -site=* | --site=* | --sit=*)
1234 site=$ac_optarg ;;
1236 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1237 ac_prev=srcdir ;;
1238 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1239 srcdir=$ac_optarg ;;
1241 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1242 | --syscon | --sysco | --sysc | --sys | --sy)
1243 ac_prev=sysconfdir ;;
1244 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1245 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1246 sysconfdir=$ac_optarg ;;
1248 -target | --target | --targe | --targ | --tar | --ta | --t)
1249 ac_prev=target_alias ;;
1250 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1251 target_alias=$ac_optarg ;;
1253 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1254 verbose=yes ;;
1256 -version | --version | --versio | --versi | --vers | -V)
1257 ac_init_version=: ;;
1259 -with-* | --with-*)
1260 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1261 # Reject names that are not valid shell variable names.
1262 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1263 { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1264 { (exit 1); exit 1; }; }
1265 ac_useropt_orig=$ac_useropt
1266 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1267 case $ac_user_opts in
1269 "with_$ac_useropt"
1270 "*) ;;
1271 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1272 ac_unrecognized_sep=', ';;
1273 esac
1274 eval with_$ac_useropt=\$ac_optarg ;;
1276 -without-* | --without-*)
1277 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1278 # Reject names that are not valid shell variable names.
1279 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1280 { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1281 { (exit 1); exit 1; }; }
1282 ac_useropt_orig=$ac_useropt
1283 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1284 case $ac_user_opts in
1286 "with_$ac_useropt"
1287 "*) ;;
1288 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1289 ac_unrecognized_sep=', ';;
1290 esac
1291 eval with_$ac_useropt=no ;;
1293 --x)
1294 # Obsolete; use --with-x.
1295 with_x=yes ;;
1297 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1298 | --x-incl | --x-inc | --x-in | --x-i)
1299 ac_prev=x_includes ;;
1300 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1301 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1302 x_includes=$ac_optarg ;;
1304 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1305 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1306 ac_prev=x_libraries ;;
1307 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1308 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1309 x_libraries=$ac_optarg ;;
1311 -*) { $as_echo "$as_me: error: unrecognized option: $ac_option
1312 Try \`$0 --help' for more information." >&2
1313 { (exit 1); exit 1; }; }
1316 *=*)
1317 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1318 # Reject names that are not valid shell variable names.
1319 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
1320 { $as_echo "$as_me: error: invalid variable name: $ac_envvar" >&2
1321 { (exit 1); exit 1; }; }
1322 eval $ac_envvar=\$ac_optarg
1323 export $ac_envvar ;;
1326 # FIXME: should be removed in autoconf 3.0.
1327 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1328 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1329 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1330 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1333 esac
1334 done
1336 if test -n "$ac_prev"; then
1337 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1338 { $as_echo "$as_me: error: missing argument to $ac_option" >&2
1339 { (exit 1); exit 1; }; }
1342 if test -n "$ac_unrecognized_opts"; then
1343 case $enable_option_checking in
1344 no) ;;
1345 fatal) { $as_echo "$as_me: error: unrecognized options: $ac_unrecognized_opts" >&2
1346 { (exit 1); exit 1; }; } ;;
1347 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1348 esac
1351 # Check all directory arguments for consistency.
1352 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1353 datadir sysconfdir sharedstatedir localstatedir includedir \
1354 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1355 libdir localedir mandir
1357 eval ac_val=\$$ac_var
1358 # Remove trailing slashes.
1359 case $ac_val in
1360 */ )
1361 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1362 eval $ac_var=\$ac_val;;
1363 esac
1364 # Be sure to have absolute directory names.
1365 case $ac_val in
1366 [\\/$]* | ?:[\\/]* ) continue;;
1367 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1368 esac
1369 { $as_echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
1370 { (exit 1); exit 1; }; }
1371 done
1373 # There might be people who depend on the old broken behavior: `$host'
1374 # used to hold the argument of --host etc.
1375 # FIXME: To remove some day.
1376 build=$build_alias
1377 host=$host_alias
1378 target=$target_alias
1380 # FIXME: To remove some day.
1381 if test "x$host_alias" != x; then
1382 if test "x$build_alias" = x; then
1383 cross_compiling=maybe
1384 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1385 If a cross compiler is detected then cross compile mode will be used." >&2
1386 elif test "x$build_alias" != "x$host_alias"; then
1387 cross_compiling=yes
1391 ac_tool_prefix=
1392 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1394 test "$silent" = yes && exec 6>/dev/null
1397 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1398 ac_ls_di=`ls -di .` &&
1399 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1400 { $as_echo "$as_me: error: working directory cannot be determined" >&2
1401 { (exit 1); exit 1; }; }
1402 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1403 { $as_echo "$as_me: error: pwd does not report name of working directory" >&2
1404 { (exit 1); exit 1; }; }
1407 # Find the source files, if location was not specified.
1408 if test -z "$srcdir"; then
1409 ac_srcdir_defaulted=yes
1410 # Try the directory containing this script, then the parent directory.
1411 ac_confdir=`$as_dirname -- "$as_myself" ||
1412 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1413 X"$as_myself" : 'X\(//\)[^/]' \| \
1414 X"$as_myself" : 'X\(//\)$' \| \
1415 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1416 $as_echo X"$as_myself" |
1417 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1418 s//\1/
1421 /^X\(\/\/\)[^/].*/{
1422 s//\1/
1425 /^X\(\/\/\)$/{
1426 s//\1/
1429 /^X\(\/\).*/{
1430 s//\1/
1433 s/.*/./; q'`
1434 srcdir=$ac_confdir
1435 if test ! -r "$srcdir/$ac_unique_file"; then
1436 srcdir=..
1438 else
1439 ac_srcdir_defaulted=no
1441 if test ! -r "$srcdir/$ac_unique_file"; then
1442 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1443 { $as_echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
1444 { (exit 1); exit 1; }; }
1446 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1447 ac_abs_confdir=`(
1448 cd "$srcdir" && test -r "./$ac_unique_file" || { $as_echo "$as_me: error: $ac_msg" >&2
1449 { (exit 1); exit 1; }; }
1450 pwd)`
1451 # When building in place, set srcdir=.
1452 if test "$ac_abs_confdir" = "$ac_pwd"; then
1453 srcdir=.
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
1469 # Report the --help message.
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.
1477 Usage: $0 [OPTION]... [VAR=VALUE]...
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.
1482 Defaults for the options are specified in brackets.
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 \`..']
1495 Installation directories:
1496 --prefix=PREFIX install architecture-independent files in PREFIX
1497 [$ac_default_prefix]
1498 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1499 [PREFIX]
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'.
1506 For better control, use the options below.
1508 Fine tuning of the installation directories:
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]
1528 _ACEOF
1530 cat <<\_ACEOF
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
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 _ACEOF
1543 if test -n "$ac_init_help"; then
1545 cat <<\_ACEOF
1547 Optional Features:
1548 --disable-option-checking ignore unrecognized --enable/--with options
1549 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1550 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1551 --disable-dependency-tracking speeds up one-time build
1552 --enable-dependency-tracking do not reject slow dependency extractors
1553 --enable-shared[=PKGS] build shared libraries [default=no]
1554 --enable-static[=PKGS] build static libraries [default=yes]
1555 --enable-fast-install[=PKGS]
1556 optimize for fast installation [default=yes]
1557 --disable-libtool-lock avoid locking (might break parallel builds)
1558 --enable-relocatable install a package that can be moved in the filesystem
1560 Optional Packages:
1561 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1562 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1563 --with-pic try to use only PIC/non-PIC objects [default=use
1564 both]
1565 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
1567 Some influential environment variables:
1568 CC C compiler command
1569 CFLAGS C compiler flags
1570 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1571 nonstandard directory <lib dir>
1572 LIBS libraries to pass to the linker, e.g. -l<library>
1573 CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1574 you have headers in a nonstandard directory <include dir>
1575 CPP C preprocessor
1577 Use these variables to override the choices made by `configure' or to help
1578 it to find libraries and programs with nonstandard names/locations.
1580 _ACEOF
1581 ac_status=$?
1584 if test "$ac_init_help" = "recursive"; then
1585 # If there are subdirs, report their specific --help.
1586 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1587 test -d "$ac_dir" ||
1588 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1589 continue
1590 ac_builddir=.
1592 case "$ac_dir" in
1593 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1595 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1596 # A ".." for each directory in $ac_dir_suffix.
1597 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1598 case $ac_top_builddir_sub in
1599 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1600 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1601 esac ;;
1602 esac
1603 ac_abs_top_builddir=$ac_pwd
1604 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1605 # for backward compatibility:
1606 ac_top_builddir=$ac_top_build_prefix
1608 case $srcdir in
1609 .) # We are building in place.
1610 ac_srcdir=.
1611 ac_top_srcdir=$ac_top_builddir_sub
1612 ac_abs_top_srcdir=$ac_pwd ;;
1613 [\\/]* | ?:[\\/]* ) # Absolute name.
1614 ac_srcdir=$srcdir$ac_dir_suffix;
1615 ac_top_srcdir=$srcdir
1616 ac_abs_top_srcdir=$srcdir ;;
1617 *) # Relative name.
1618 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1619 ac_top_srcdir=$ac_top_build_prefix$srcdir
1620 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1621 esac
1622 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1624 cd "$ac_dir" || { ac_status=$?; continue; }
1625 # Check for guested configure.
1626 if test -f "$ac_srcdir/configure.gnu"; then
1627 echo &&
1628 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1629 elif test -f "$ac_srcdir/configure"; then
1630 echo &&
1631 $SHELL "$ac_srcdir/configure" --help=recursive
1632 else
1633 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1634 fi || ac_status=$?
1635 cd "$ac_pwd" || { ac_status=$?; break; }
1636 done
1639 test -n "$ac_init_help" && exit $ac_status
1640 if $ac_init_version; then
1641 cat <<\_ACEOF
1642 configure
1643 generated by GNU Autoconf 2.63
1645 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
1646 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
1647 This configure script is free software; the Free Software Foundation
1648 gives unlimited permission to copy, distribute and modify it.
1649 _ACEOF
1650 exit
1652 cat >config.log <<_ACEOF
1653 This file contains any messages produced by compilers while
1654 running configure, to aid debugging if configure makes a mistake.
1656 It was created by $as_me, which was
1657 generated by GNU Autoconf 2.63. Invocation command line was
1659 $ $0 $@
1661 _ACEOF
1662 exec 5>>config.log
1664 cat <<_ASUNAME
1665 ## --------- ##
1666 ## Platform. ##
1667 ## --------- ##
1669 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1670 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1671 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1672 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1673 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1675 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1676 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
1678 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
1679 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
1680 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1681 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
1682 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
1683 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
1684 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
1686 _ASUNAME
1688 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1689 for as_dir in $PATH
1691 IFS=$as_save_IFS
1692 test -z "$as_dir" && as_dir=.
1693 $as_echo "PATH: $as_dir"
1694 done
1695 IFS=$as_save_IFS
1697 } >&5
1699 cat >&5 <<_ACEOF
1702 ## ----------- ##
1703 ## Core tests. ##
1704 ## ----------- ##
1706 _ACEOF
1709 # Keep a trace of the command line.
1710 # Strip out --no-create and --no-recursion so they do not pile up.
1711 # Strip out --silent because we don't want to record it for future runs.
1712 # Also quote any args containing shell meta-characters.
1713 # Make two passes to allow for proper duplicate-argument suppression.
1714 ac_configure_args=
1715 ac_configure_args0=
1716 ac_configure_args1=
1717 ac_must_keep_next=false
1718 for ac_pass in 1 2
1720 for ac_arg
1722 case $ac_arg in
1723 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1724 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1725 | -silent | --silent | --silen | --sile | --sil)
1726 continue ;;
1727 *\'*)
1728 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1729 esac
1730 case $ac_pass in
1731 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1733 ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1734 if test $ac_must_keep_next = true; then
1735 ac_must_keep_next=false # Got value, back to normal.
1736 else
1737 case $ac_arg in
1738 *=* | --config-cache | -C | -disable-* | --disable-* \
1739 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1740 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1741 | -with-* | --with-* | -without-* | --without-* | --x)
1742 case "$ac_configure_args0 " in
1743 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1744 esac
1746 -* ) ac_must_keep_next=true ;;
1747 esac
1749 ac_configure_args="$ac_configure_args '$ac_arg'"
1751 esac
1752 done
1753 done
1754 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1755 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1757 # When interrupted or exit'd, cleanup temporary files, and complete
1758 # config.log. We remove comments because anyway the quotes in there
1759 # would cause problems or look ugly.
1760 # WARNING: Use '\'' to represent an apostrophe within the trap.
1761 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1762 trap 'exit_status=$?
1763 # Save into config.log some information that might help in debugging.
1765 echo
1767 cat <<\_ASBOX
1768 ## ---------------- ##
1769 ## Cache variables. ##
1770 ## ---------------- ##
1771 _ASBOX
1772 echo
1773 # The following way of writing the cache mishandles newlines in values,
1775 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1776 eval ac_val=\$$ac_var
1777 case $ac_val in #(
1778 *${as_nl}*)
1779 case $ac_var in #(
1780 *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
1781 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
1782 esac
1783 case $ac_var in #(
1784 _ | IFS | as_nl) ;; #(
1785 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
1786 *) $as_unset $ac_var ;;
1787 esac ;;
1788 esac
1789 done
1790 (set) 2>&1 |
1791 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1792 *${as_nl}ac_space=\ *)
1793 sed -n \
1794 "s/'\''/'\''\\\\'\'''\''/g;
1795 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1796 ;; #(
1798 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1800 esac |
1801 sort
1803 echo
1805 cat <<\_ASBOX
1806 ## ----------------- ##
1807 ## Output variables. ##
1808 ## ----------------- ##
1809 _ASBOX
1810 echo
1811 for ac_var in $ac_subst_vars
1813 eval ac_val=\$$ac_var
1814 case $ac_val in
1815 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1816 esac
1817 $as_echo "$ac_var='\''$ac_val'\''"
1818 done | sort
1819 echo
1821 if test -n "$ac_subst_files"; then
1822 cat <<\_ASBOX
1823 ## ------------------- ##
1824 ## File substitutions. ##
1825 ## ------------------- ##
1826 _ASBOX
1827 echo
1828 for ac_var in $ac_subst_files
1830 eval ac_val=\$$ac_var
1831 case $ac_val in
1832 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1833 esac
1834 $as_echo "$ac_var='\''$ac_val'\''"
1835 done | sort
1836 echo
1839 if test -s confdefs.h; then
1840 cat <<\_ASBOX
1841 ## ----------- ##
1842 ## confdefs.h. ##
1843 ## ----------- ##
1844 _ASBOX
1845 echo
1846 cat confdefs.h
1847 echo
1849 test "$ac_signal" != 0 &&
1850 $as_echo "$as_me: caught signal $ac_signal"
1851 $as_echo "$as_me: exit $exit_status"
1852 } >&5
1853 rm -f core *.core core.conftest.* &&
1854 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1855 exit $exit_status
1857 for ac_signal in 1 2 13 15; do
1858 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1859 done
1860 ac_signal=0
1862 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1863 rm -f -r conftest* confdefs.h
1865 # Predefined preprocessor variables.
1867 cat >>confdefs.h <<_ACEOF
1868 #define PACKAGE_NAME "$PACKAGE_NAME"
1869 _ACEOF
1872 cat >>confdefs.h <<_ACEOF
1873 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1874 _ACEOF
1877 cat >>confdefs.h <<_ACEOF
1878 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1879 _ACEOF
1882 cat >>confdefs.h <<_ACEOF
1883 #define PACKAGE_STRING "$PACKAGE_STRING"
1884 _ACEOF
1887 cat >>confdefs.h <<_ACEOF
1888 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1889 _ACEOF
1892 # Let the site file select an alternate cache file if it wants to.
1893 # Prefer an explicitly selected file to automatically selected ones.
1894 ac_site_file1=NONE
1895 ac_site_file2=NONE
1896 if test -n "$CONFIG_SITE"; then
1897 ac_site_file1=$CONFIG_SITE
1898 elif test "x$prefix" != xNONE; then
1899 ac_site_file1=$prefix/share/config.site
1900 ac_site_file2=$prefix/etc/config.site
1901 else
1902 ac_site_file1=$ac_default_prefix/share/config.site
1903 ac_site_file2=$ac_default_prefix/etc/config.site
1905 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
1907 test "x$ac_site_file" = xNONE && continue
1908 if test -r "$ac_site_file"; then
1909 { $as_echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1910 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
1911 sed 's/^/| /' "$ac_site_file" >&5
1912 . "$ac_site_file"
1914 done
1916 if test -r "$cache_file"; then
1917 # Some versions of bash will fail to source /dev/null (special
1918 # files actually), so we avoid doing that.
1919 if test -f "$cache_file"; then
1920 { $as_echo "$as_me:$LINENO: loading cache $cache_file" >&5
1921 $as_echo "$as_me: loading cache $cache_file" >&6;}
1922 case $cache_file in
1923 [\\/]* | ?:[\\/]* ) . "$cache_file";;
1924 *) . "./$cache_file";;
1925 esac
1927 else
1928 { $as_echo "$as_me:$LINENO: creating cache $cache_file" >&5
1929 $as_echo "$as_me: creating cache $cache_file" >&6;}
1930 >$cache_file
1933 # Check that the precious variables saved in the cache have kept the same
1934 # value.
1935 ac_cache_corrupted=false
1936 for ac_var in $ac_precious_vars; do
1937 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1938 eval ac_new_set=\$ac_env_${ac_var}_set
1939 eval ac_old_val=\$ac_cv_env_${ac_var}_value
1940 eval ac_new_val=\$ac_env_${ac_var}_value
1941 case $ac_old_set,$ac_new_set in
1942 set,)
1943 { $as_echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1944 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1945 ac_cache_corrupted=: ;;
1946 ,set)
1947 { $as_echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1948 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1949 ac_cache_corrupted=: ;;
1950 ,);;
1952 if test "x$ac_old_val" != "x$ac_new_val"; then
1953 # differences in whitespace do not lead to failure.
1954 ac_old_val_w=`echo x $ac_old_val`
1955 ac_new_val_w=`echo x $ac_new_val`
1956 if test "$ac_old_val_w" != "$ac_new_val_w"; then
1957 { $as_echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1958 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1959 ac_cache_corrupted=:
1960 else
1961 { $as_echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
1962 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
1963 eval $ac_var=\$ac_old_val
1965 { $as_echo "$as_me:$LINENO: former value: \`$ac_old_val'" >&5
1966 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
1967 { $as_echo "$as_me:$LINENO: current value: \`$ac_new_val'" >&5
1968 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
1969 fi;;
1970 esac
1971 # Pass precious variables to config.status.
1972 if test "$ac_new_set" = set; then
1973 case $ac_new_val in
1974 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1975 *) ac_arg=$ac_var=$ac_new_val ;;
1976 esac
1977 case " $ac_configure_args " in
1978 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1979 *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1980 esac
1982 done
1983 if $ac_cache_corrupted; then
1984 { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1985 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
1986 { $as_echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1987 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1988 { { $as_echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1989 $as_echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1990 { (exit 1); exit 1; }; }
2009 ac_ext=c
2010 ac_cpp='$CPP $CPPFLAGS'
2011 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2012 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2013 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2017 ac_aux_dir=
2018 for ac_dir in build-aux "$srcdir"/build-aux; do
2019 if test -f "$ac_dir/install-sh"; then
2020 ac_aux_dir=$ac_dir
2021 ac_install_sh="$ac_aux_dir/install-sh -c"
2022 break
2023 elif test -f "$ac_dir/install.sh"; then
2024 ac_aux_dir=$ac_dir
2025 ac_install_sh="$ac_aux_dir/install.sh -c"
2026 break
2027 elif test -f "$ac_dir/shtool"; then
2028 ac_aux_dir=$ac_dir
2029 ac_install_sh="$ac_aux_dir/shtool install -c"
2030 break
2032 done
2033 if test -z "$ac_aux_dir"; then
2034 { { $as_echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in build-aux \"$srcdir\"/build-aux" >&5
2035 $as_echo "$as_me: error: cannot find install-sh or install.sh in build-aux \"$srcdir\"/build-aux" >&2;}
2036 { (exit 1); exit 1; }; }
2039 # These three variables are undocumented and unsupported,
2040 # and are intended to be withdrawn in a future Autoconf release.
2041 # They can cause serious problems if a builder's source tree is in a directory
2042 # whose full name contains unusual characters.
2043 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
2044 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
2045 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
2051 case $TERM in
2052 # for the most important terminal types we directly know the sequences
2053 xterm*|vt220*)
2054 term_bold=`${AWK:-awk} 'BEGIN { printf("%c%c%c%c", 27, 91, 49, 109); }' </dev/null 2>/dev/null`
2055 term_norm=`${AWK:-awk} 'BEGIN { printf("%c%c%c", 27, 91, 109); }' </dev/null 2>/dev/null`
2057 vt100*)
2058 term_bold=`${AWK:-awk} 'BEGIN { printf("%c%c%c%c%c%c", 27, 91, 49, 109, 0, 0); }' </dev/null 2>/dev/null`
2059 term_norm=`${AWK:-awk} 'BEGIN { printf("%c%c%c%c%c", 27, 91, 109, 0, 0); }' </dev/null 2>/dev/null`
2061 # for all others, we try to use a possibly existing `tput' or `tcout' utility
2063 paths=`echo "$PATH" | sed -e 's/:/ /g'`
2064 for tool in tput tcout; do
2065 for dir in $paths; do
2066 if test -r "$dir/$tool"; then
2067 for seq in bold md smso; do # 'smso' is last
2068 bold="`$dir/$tool $seq 2>/dev/null`"
2069 if test -n "$bold"; then
2070 term_bold="$bold"
2071 break
2073 done
2074 if test -n "$term_bold"; then
2075 for seq in sgr0 me rmso reset; do # 'reset' is last
2076 norm="`$dir/$tool $seq 2>/dev/null`"
2077 if test -n "$norm"; then
2078 term_norm="$norm"
2079 break
2081 done
2083 break
2085 done
2086 if test -n "$term_bold" && test -n "$term_norm"; then
2087 break
2089 done
2091 esac
2092 echo "$term_bold" | tr -d '\n' > termbold
2093 echo "$term_norm" | tr -d '\n' > termnorm
2096 { echo; echo "${term_bold}Build Tools:${term_norm}"; } >& 6
2098 am__api_version='1.10'
2100 # Find a good install program. We prefer a C program (faster),
2101 # so one script is as good as another. But avoid the broken or
2102 # incompatible versions:
2103 # SysV /etc/install, /usr/sbin/install
2104 # SunOS /usr/etc/install
2105 # IRIX /sbin/install
2106 # AIX /bin/install
2107 # AmigaOS /C/install, which installs bootblocks on floppy discs
2108 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2109 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2110 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2111 # OS/2's system install, which has a completely different semantic
2112 # ./install, which can be erroneously created by make from ./install.sh.
2113 # Reject install programs that cannot install multiple files.
2114 { $as_echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
2115 $as_echo_n "checking for a BSD-compatible install... " >&6; }
2116 if test -z "$INSTALL"; then
2117 if test "${ac_cv_path_install+set}" = set; then
2118 $as_echo_n "(cached) " >&6
2119 else
2120 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2121 for as_dir in $PATH
2123 IFS=$as_save_IFS
2124 test -z "$as_dir" && as_dir=.
2125 # Account for people who put trailing slashes in PATH elements.
2126 case $as_dir/ in
2127 ./ | .// | /cC/* | \
2128 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
2129 ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
2130 /usr/ucb/* ) ;;
2132 # OSF1 and SCO ODT 3.0 have their own names for install.
2133 # Don't use installbsd from OSF since it installs stuff as root
2134 # by default.
2135 for ac_prog in ginstall scoinst install; do
2136 for ac_exec_ext in '' $ac_executable_extensions; do
2137 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
2138 if test $ac_prog = install &&
2139 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
2140 # AIX install. It has an incompatible calling convention.
2142 elif test $ac_prog = install &&
2143 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
2144 # program-specific install script used by HP pwplus--don't use.
2146 else
2147 rm -rf conftest.one conftest.two conftest.dir
2148 echo one > conftest.one
2149 echo two > conftest.two
2150 mkdir conftest.dir
2151 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
2152 test -s conftest.one && test -s conftest.two &&
2153 test -s conftest.dir/conftest.one &&
2154 test -s conftest.dir/conftest.two
2155 then
2156 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
2157 break 3
2161 done
2162 done
2164 esac
2166 done
2167 IFS=$as_save_IFS
2169 rm -rf conftest.one conftest.two conftest.dir
2172 if test "${ac_cv_path_install+set}" = set; then
2173 INSTALL=$ac_cv_path_install
2174 else
2175 # As a last resort, use the slow shell script. Don't cache a
2176 # value for INSTALL within a source directory, because that will
2177 # break other packages using the cache if that directory is
2178 # removed, or if the value is a relative name.
2179 INSTALL=$ac_install_sh
2182 { $as_echo "$as_me:$LINENO: result: $INSTALL" >&5
2183 $as_echo "$INSTALL" >&6; }
2185 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2186 # It thinks the first close brace ends the variable substitution.
2187 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2189 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2191 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2193 { $as_echo "$as_me:$LINENO: checking whether build environment is sane" >&5
2194 $as_echo_n "checking whether build environment is sane... " >&6; }
2195 # Just in case
2196 sleep 1
2197 echo timestamp > conftest.file
2198 # Do `set' in a subshell so we don't clobber the current shell's
2199 # arguments. Must try -L first in case configure is actually a
2200 # symlink; some systems play weird games with the mod time of symlinks
2201 # (eg FreeBSD returns the mod time of the symlink's containing
2202 # directory).
2203 if (
2204 set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
2205 if test "$*" = "X"; then
2206 # -L didn't work.
2207 set X `ls -t $srcdir/configure conftest.file`
2209 rm -f conftest.file
2210 if test "$*" != "X $srcdir/configure conftest.file" \
2211 && test "$*" != "X conftest.file $srcdir/configure"; then
2213 # If neither matched, then we have a broken ls. This can happen
2214 # if, for instance, CONFIG_SHELL is bash and it inherits a
2215 # broken ls alias from the environment. This has actually
2216 # happened. Such a system could not be considered "sane".
2217 { { $as_echo "$as_me:$LINENO: error: ls -t appears to fail. Make sure there is not a broken
2218 alias in your environment" >&5
2219 $as_echo "$as_me: error: ls -t appears to fail. Make sure there is not a broken
2220 alias in your environment" >&2;}
2221 { (exit 1); exit 1; }; }
2224 test "$2" = conftest.file
2226 then
2227 # Ok.
2229 else
2230 { { $as_echo "$as_me:$LINENO: error: newly created file is older than distributed files!
2231 Check your system clock" >&5
2232 $as_echo "$as_me: error: newly created file is older than distributed files!
2233 Check your system clock" >&2;}
2234 { (exit 1); exit 1; }; }
2236 { $as_echo "$as_me:$LINENO: result: yes" >&5
2237 $as_echo "yes" >&6; }
2238 test "$program_prefix" != NONE &&
2239 program_transform_name="s&^&$program_prefix&;$program_transform_name"
2240 # Use a double $ so make ignores it.
2241 test "$program_suffix" != NONE &&
2242 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
2243 # Double any \ or $.
2244 # By default was `s,x,x', remove it if useless.
2245 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
2246 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
2248 # expand $ac_aux_dir to an absolute path
2249 am_aux_dir=`cd $ac_aux_dir && pwd`
2251 test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
2252 # Use eval to expand $SHELL
2253 if eval "$MISSING --run true"; then
2254 am_missing_run="$MISSING --run "
2255 else
2256 am_missing_run=
2257 { $as_echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5
2258 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
2261 { $as_echo "$as_me:$LINENO: checking for a thread-safe mkdir -p" >&5
2262 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
2263 if test -z "$MKDIR_P"; then
2264 if test "${ac_cv_path_mkdir+set}" = set; then
2265 $as_echo_n "(cached) " >&6
2266 else
2267 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2268 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
2270 IFS=$as_save_IFS
2271 test -z "$as_dir" && as_dir=.
2272 for ac_prog in mkdir gmkdir; do
2273 for ac_exec_ext in '' $ac_executable_extensions; do
2274 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
2275 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
2276 'mkdir (GNU coreutils) '* | \
2277 'mkdir (coreutils) '* | \
2278 'mkdir (fileutils) '4.1*)
2279 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
2280 break 3;;
2281 esac
2282 done
2283 done
2284 done
2285 IFS=$as_save_IFS
2289 if test "${ac_cv_path_mkdir+set}" = set; then
2290 MKDIR_P="$ac_cv_path_mkdir -p"
2291 else
2292 # As a last resort, use the slow shell script. Don't cache a
2293 # value for MKDIR_P within a source directory, because that will
2294 # break other packages using the cache if that directory is
2295 # removed, or if the value is a relative name.
2296 test -d ./--version && rmdir ./--version
2297 MKDIR_P="$ac_install_sh -d"
2300 { $as_echo "$as_me:$LINENO: result: $MKDIR_P" >&5
2301 $as_echo "$MKDIR_P" >&6; }
2303 mkdir_p="$MKDIR_P"
2304 case $mkdir_p in
2305 [\\/$]* | ?:[\\/]*) ;;
2306 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
2307 esac
2309 for ac_prog in gawk mawk nawk awk
2311 # Extract the first word of "$ac_prog", so it can be a program name with args.
2312 set dummy $ac_prog; ac_word=$2
2313 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2314 $as_echo_n "checking for $ac_word... " >&6; }
2315 if test "${ac_cv_prog_AWK+set}" = set; then
2316 $as_echo_n "(cached) " >&6
2317 else
2318 if test -n "$AWK"; then
2319 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2320 else
2321 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2322 for as_dir in $PATH
2324 IFS=$as_save_IFS
2325 test -z "$as_dir" && as_dir=.
2326 for ac_exec_ext in '' $ac_executable_extensions; do
2327 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2328 ac_cv_prog_AWK="$ac_prog"
2329 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2330 break 2
2332 done
2333 done
2334 IFS=$as_save_IFS
2338 AWK=$ac_cv_prog_AWK
2339 if test -n "$AWK"; then
2340 { $as_echo "$as_me:$LINENO: result: $AWK" >&5
2341 $as_echo "$AWK" >&6; }
2342 else
2343 { $as_echo "$as_me:$LINENO: result: no" >&5
2344 $as_echo "no" >&6; }
2348 test -n "$AWK" && break
2349 done
2351 { $as_echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
2352 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
2353 set x ${MAKE-make}
2354 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
2355 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then
2356 $as_echo_n "(cached) " >&6
2357 else
2358 cat >conftest.make <<\_ACEOF
2359 SHELL = /bin/sh
2360 all:
2361 @echo '@@@%%%=$(MAKE)=@@@%%%'
2362 _ACEOF
2363 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
2364 case `${MAKE-make} -f conftest.make 2>/dev/null` in
2365 *@@@%%%=?*=@@@%%%*)
2366 eval ac_cv_prog_make_${ac_make}_set=yes;;
2368 eval ac_cv_prog_make_${ac_make}_set=no;;
2369 esac
2370 rm -f conftest.make
2372 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
2373 { $as_echo "$as_me:$LINENO: result: yes" >&5
2374 $as_echo "yes" >&6; }
2375 SET_MAKE=
2376 else
2377 { $as_echo "$as_me:$LINENO: result: no" >&5
2378 $as_echo "no" >&6; }
2379 SET_MAKE="MAKE=${MAKE-make}"
2382 rm -rf .tst 2>/dev/null
2383 mkdir .tst 2>/dev/null
2384 if test -d .tst; then
2385 am__leading_dot=.
2386 else
2387 am__leading_dot=_
2389 rmdir .tst 2>/dev/null
2391 if test "`cd $srcdir && pwd`" != "`pwd`"; then
2392 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
2393 # is not polluted with repeated "-I."
2394 am__isrc=' -I$(srcdir)'
2395 # test to see if srcdir already configured
2396 if test -f $srcdir/config.status; then
2397 { { $as_echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5
2398 $as_echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;}
2399 { (exit 1); exit 1; }; }
2403 # test whether we have cygpath
2404 if test -z "$CYGPATH_W"; then
2405 if (cygpath --version) >/dev/null 2>/dev/null; then
2406 CYGPATH_W='cygpath -w'
2407 else
2408 CYGPATH_W=echo
2413 # Define the identity of the package.
2414 PACKAGE=libsigsegv
2415 VERSION=2.7-pre1
2418 cat >>confdefs.h <<_ACEOF
2419 #define PACKAGE "$PACKAGE"
2420 _ACEOF
2423 cat >>confdefs.h <<_ACEOF
2424 #define VERSION "$VERSION"
2425 _ACEOF
2427 # Some tools Automake needs.
2429 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
2432 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
2435 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
2438 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
2441 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
2443 install_sh=${install_sh-"\$(SHELL) $am_aux_dir/install-sh"}
2445 # Installed binaries are usually stripped using `strip' when the user
2446 # run `make install-strip'. However `strip' might not be the right
2447 # tool to use in cross-compilation environments, therefore Automake
2448 # will honor the `STRIP' environment variable to overrule this program.
2449 if test "$cross_compiling" != no; then
2450 if test -n "$ac_tool_prefix"; then
2451 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
2452 set dummy ${ac_tool_prefix}strip; ac_word=$2
2453 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2454 $as_echo_n "checking for $ac_word... " >&6; }
2455 if test "${ac_cv_prog_STRIP+set}" = set; then
2456 $as_echo_n "(cached) " >&6
2457 else
2458 if test -n "$STRIP"; then
2459 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
2460 else
2461 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2462 for as_dir in $PATH
2464 IFS=$as_save_IFS
2465 test -z "$as_dir" && as_dir=.
2466 for ac_exec_ext in '' $ac_executable_extensions; do
2467 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2468 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
2469 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2470 break 2
2472 done
2473 done
2474 IFS=$as_save_IFS
2478 STRIP=$ac_cv_prog_STRIP
2479 if test -n "$STRIP"; then
2480 { $as_echo "$as_me:$LINENO: result: $STRIP" >&5
2481 $as_echo "$STRIP" >&6; }
2482 else
2483 { $as_echo "$as_me:$LINENO: result: no" >&5
2484 $as_echo "no" >&6; }
2489 if test -z "$ac_cv_prog_STRIP"; then
2490 ac_ct_STRIP=$STRIP
2491 # Extract the first word of "strip", so it can be a program name with args.
2492 set dummy strip; ac_word=$2
2493 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2494 $as_echo_n "checking for $ac_word... " >&6; }
2495 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
2496 $as_echo_n "(cached) " >&6
2497 else
2498 if test -n "$ac_ct_STRIP"; then
2499 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
2500 else
2501 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2502 for as_dir in $PATH
2504 IFS=$as_save_IFS
2505 test -z "$as_dir" && as_dir=.
2506 for ac_exec_ext in '' $ac_executable_extensions; do
2507 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2508 ac_cv_prog_ac_ct_STRIP="strip"
2509 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2510 break 2
2512 done
2513 done
2514 IFS=$as_save_IFS
2518 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
2519 if test -n "$ac_ct_STRIP"; then
2520 { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
2521 $as_echo "$ac_ct_STRIP" >&6; }
2522 else
2523 { $as_echo "$as_me:$LINENO: result: no" >&5
2524 $as_echo "no" >&6; }
2527 if test "x$ac_ct_STRIP" = x; then
2528 STRIP=":"
2529 else
2530 case $cross_compiling:$ac_tool_warned in
2531 yes:)
2532 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
2533 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2534 ac_tool_warned=yes ;;
2535 esac
2536 STRIP=$ac_ct_STRIP
2538 else
2539 STRIP="$ac_cv_prog_STRIP"
2543 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
2545 # We need awk for the "check" target. The system "awk" is bad on
2546 # some platforms.
2547 # Always define AMTAR for backward compatibility.
2549 AMTAR=${AMTAR-"${am_missing_run}tar"}
2551 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
2557 ac_config_headers="$ac_config_headers config.h"
2560 ac_ext=c
2561 ac_cpp='$CPP $CPPFLAGS'
2562 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2563 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2564 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2565 if test -n "$ac_tool_prefix"; then
2566 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2567 set dummy ${ac_tool_prefix}gcc; ac_word=$2
2568 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2569 $as_echo_n "checking for $ac_word... " >&6; }
2570 if test "${ac_cv_prog_CC+set}" = set; then
2571 $as_echo_n "(cached) " >&6
2572 else
2573 if test -n "$CC"; then
2574 ac_cv_prog_CC="$CC" # Let the user override the test.
2575 else
2576 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2577 for as_dir in $PATH
2579 IFS=$as_save_IFS
2580 test -z "$as_dir" && as_dir=.
2581 for ac_exec_ext in '' $ac_executable_extensions; do
2582 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2583 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2584 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2585 break 2
2587 done
2588 done
2589 IFS=$as_save_IFS
2593 CC=$ac_cv_prog_CC
2594 if test -n "$CC"; then
2595 { $as_echo "$as_me:$LINENO: result: $CC" >&5
2596 $as_echo "$CC" >&6; }
2597 else
2598 { $as_echo "$as_me:$LINENO: result: no" >&5
2599 $as_echo "no" >&6; }
2604 if test -z "$ac_cv_prog_CC"; then
2605 ac_ct_CC=$CC
2606 # Extract the first word of "gcc", so it can be a program name with args.
2607 set dummy gcc; ac_word=$2
2608 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2609 $as_echo_n "checking for $ac_word... " >&6; }
2610 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2611 $as_echo_n "(cached) " >&6
2612 else
2613 if test -n "$ac_ct_CC"; then
2614 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2615 else
2616 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2617 for as_dir in $PATH
2619 IFS=$as_save_IFS
2620 test -z "$as_dir" && as_dir=.
2621 for ac_exec_ext in '' $ac_executable_extensions; do
2622 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2623 ac_cv_prog_ac_ct_CC="gcc"
2624 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2625 break 2
2627 done
2628 done
2629 IFS=$as_save_IFS
2633 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2634 if test -n "$ac_ct_CC"; then
2635 { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2636 $as_echo "$ac_ct_CC" >&6; }
2637 else
2638 { $as_echo "$as_me:$LINENO: result: no" >&5
2639 $as_echo "no" >&6; }
2642 if test "x$ac_ct_CC" = x; then
2643 CC=""
2644 else
2645 case $cross_compiling:$ac_tool_warned in
2646 yes:)
2647 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
2648 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2649 ac_tool_warned=yes ;;
2650 esac
2651 CC=$ac_ct_CC
2653 else
2654 CC="$ac_cv_prog_CC"
2657 if test -z "$CC"; then
2658 if test -n "$ac_tool_prefix"; then
2659 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2660 set dummy ${ac_tool_prefix}cc; ac_word=$2
2661 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2662 $as_echo_n "checking for $ac_word... " >&6; }
2663 if test "${ac_cv_prog_CC+set}" = set; then
2664 $as_echo_n "(cached) " >&6
2665 else
2666 if test -n "$CC"; then
2667 ac_cv_prog_CC="$CC" # Let the user override the test.
2668 else
2669 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2670 for as_dir in $PATH
2672 IFS=$as_save_IFS
2673 test -z "$as_dir" && as_dir=.
2674 for ac_exec_ext in '' $ac_executable_extensions; do
2675 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2676 ac_cv_prog_CC="${ac_tool_prefix}cc"
2677 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2678 break 2
2680 done
2681 done
2682 IFS=$as_save_IFS
2686 CC=$ac_cv_prog_CC
2687 if test -n "$CC"; then
2688 { $as_echo "$as_me:$LINENO: result: $CC" >&5
2689 $as_echo "$CC" >&6; }
2690 else
2691 { $as_echo "$as_me:$LINENO: result: no" >&5
2692 $as_echo "no" >&6; }
2698 if test -z "$CC"; then
2699 # Extract the first word of "cc", so it can be a program name with args.
2700 set dummy cc; ac_word=$2
2701 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2702 $as_echo_n "checking for $ac_word... " >&6; }
2703 if test "${ac_cv_prog_CC+set}" = set; then
2704 $as_echo_n "(cached) " >&6
2705 else
2706 if test -n "$CC"; then
2707 ac_cv_prog_CC="$CC" # Let the user override the test.
2708 else
2709 ac_prog_rejected=no
2710 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2711 for as_dir in $PATH
2713 IFS=$as_save_IFS
2714 test -z "$as_dir" && as_dir=.
2715 for ac_exec_ext in '' $ac_executable_extensions; do
2716 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2717 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2718 ac_prog_rejected=yes
2719 continue
2721 ac_cv_prog_CC="cc"
2722 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2723 break 2
2725 done
2726 done
2727 IFS=$as_save_IFS
2729 if test $ac_prog_rejected = yes; then
2730 # We found a bogon in the path, so make sure we never use it.
2731 set dummy $ac_cv_prog_CC
2732 shift
2733 if test $# != 0; then
2734 # We chose a different compiler from the bogus one.
2735 # However, it has the same basename, so the bogon will be chosen
2736 # first if we set CC to just the basename; use the full file name.
2737 shift
2738 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
2743 CC=$ac_cv_prog_CC
2744 if test -n "$CC"; then
2745 { $as_echo "$as_me:$LINENO: result: $CC" >&5
2746 $as_echo "$CC" >&6; }
2747 else
2748 { $as_echo "$as_me:$LINENO: result: no" >&5
2749 $as_echo "no" >&6; }
2754 if test -z "$CC"; then
2755 if test -n "$ac_tool_prefix"; then
2756 for ac_prog in cl.exe
2758 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2759 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2760 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2761 $as_echo_n "checking for $ac_word... " >&6; }
2762 if test "${ac_cv_prog_CC+set}" = set; then
2763 $as_echo_n "(cached) " >&6
2764 else
2765 if test -n "$CC"; then
2766 ac_cv_prog_CC="$CC" # Let the user override the test.
2767 else
2768 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2769 for as_dir in $PATH
2771 IFS=$as_save_IFS
2772 test -z "$as_dir" && as_dir=.
2773 for ac_exec_ext in '' $ac_executable_extensions; do
2774 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2775 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2776 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2777 break 2
2779 done
2780 done
2781 IFS=$as_save_IFS
2785 CC=$ac_cv_prog_CC
2786 if test -n "$CC"; then
2787 { $as_echo "$as_me:$LINENO: result: $CC" >&5
2788 $as_echo "$CC" >&6; }
2789 else
2790 { $as_echo "$as_me:$LINENO: result: no" >&5
2791 $as_echo "no" >&6; }
2795 test -n "$CC" && break
2796 done
2798 if test -z "$CC"; then
2799 ac_ct_CC=$CC
2800 for ac_prog in cl.exe
2802 # Extract the first word of "$ac_prog", so it can be a program name with args.
2803 set dummy $ac_prog; ac_word=$2
2804 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2805 $as_echo_n "checking for $ac_word... " >&6; }
2806 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2807 $as_echo_n "(cached) " >&6
2808 else
2809 if test -n "$ac_ct_CC"; then
2810 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2811 else
2812 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2813 for as_dir in $PATH
2815 IFS=$as_save_IFS
2816 test -z "$as_dir" && as_dir=.
2817 for ac_exec_ext in '' $ac_executable_extensions; do
2818 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2819 ac_cv_prog_ac_ct_CC="$ac_prog"
2820 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2821 break 2
2823 done
2824 done
2825 IFS=$as_save_IFS
2829 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2830 if test -n "$ac_ct_CC"; then
2831 { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2832 $as_echo "$ac_ct_CC" >&6; }
2833 else
2834 { $as_echo "$as_me:$LINENO: result: no" >&5
2835 $as_echo "no" >&6; }
2839 test -n "$ac_ct_CC" && break
2840 done
2842 if test "x$ac_ct_CC" = x; then
2843 CC=""
2844 else
2845 case $cross_compiling:$ac_tool_warned in
2846 yes:)
2847 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
2848 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2849 ac_tool_warned=yes ;;
2850 esac
2851 CC=$ac_ct_CC
2858 test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
2859 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2860 { { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2861 See \`config.log' for more details." >&5
2862 $as_echo "$as_me: error: no acceptable C compiler found in \$PATH
2863 See \`config.log' for more details." >&2;}
2864 { (exit 1); exit 1; }; }; }
2866 # Provide some information about the compiler.
2867 $as_echo "$as_me:$LINENO: checking for C compiler version" >&5
2868 set X $ac_compile
2869 ac_compiler=$2
2870 { (ac_try="$ac_compiler --version >&5"
2871 case "(($ac_try" in
2872 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2873 *) ac_try_echo=$ac_try;;
2874 esac
2875 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
2876 $as_echo "$ac_try_echo") >&5
2877 (eval "$ac_compiler --version >&5") 2>&5
2878 ac_status=$?
2879 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
2880 (exit $ac_status); }
2881 { (ac_try="$ac_compiler -v >&5"
2882 case "(($ac_try" in
2883 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2884 *) ac_try_echo=$ac_try;;
2885 esac
2886 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
2887 $as_echo "$ac_try_echo") >&5
2888 (eval "$ac_compiler -v >&5") 2>&5
2889 ac_status=$?
2890 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
2891 (exit $ac_status); }
2892 { (ac_try="$ac_compiler -V >&5"
2893 case "(($ac_try" in
2894 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2895 *) ac_try_echo=$ac_try;;
2896 esac
2897 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
2898 $as_echo "$ac_try_echo") >&5
2899 (eval "$ac_compiler -V >&5") 2>&5
2900 ac_status=$?
2901 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
2902 (exit $ac_status); }
2904 cat >conftest.$ac_ext <<_ACEOF
2905 /* confdefs.h. */
2906 _ACEOF
2907 cat confdefs.h >>conftest.$ac_ext
2908 cat >>conftest.$ac_ext <<_ACEOF
2909 /* end confdefs.h. */
2912 main ()
2916 return 0;
2918 _ACEOF
2919 ac_clean_files_save=$ac_clean_files
2920 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
2921 # Try to create an executable without -o first, disregard a.out.
2922 # It will help us diagnose broken compilers, and finding out an intuition
2923 # of exeext.
2924 { $as_echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
2925 $as_echo_n "checking for C compiler default output file name... " >&6; }
2926 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2928 # The possible output files:
2929 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
2931 ac_rmfiles=
2932 for ac_file in $ac_files
2934 case $ac_file in
2935 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
2936 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
2937 esac
2938 done
2939 rm -f $ac_rmfiles
2941 if { (ac_try="$ac_link_default"
2942 case "(($ac_try" in
2943 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2944 *) ac_try_echo=$ac_try;;
2945 esac
2946 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
2947 $as_echo "$ac_try_echo") >&5
2948 (eval "$ac_link_default") 2>&5
2949 ac_status=$?
2950 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
2951 (exit $ac_status); }; then
2952 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
2953 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
2954 # in a Makefile. We should not override ac_cv_exeext if it was cached,
2955 # so that the user can short-circuit this test for compilers unknown to
2956 # Autoconf.
2957 for ac_file in $ac_files ''
2959 test -f "$ac_file" || continue
2960 case $ac_file in
2961 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
2963 [ab].out )
2964 # We found the default executable, but exeext='' is most
2965 # certainly right.
2966 break;;
2967 *.* )
2968 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
2969 then :; else
2970 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2972 # We set ac_cv_exeext here because the later test for it is not
2973 # safe: cross compilers may not add the suffix if given an `-o'
2974 # argument, so we may need to know it at that point already.
2975 # Even if this section looks crufty: it has the advantage of
2976 # actually working.
2977 break;;
2979 break;;
2980 esac
2981 done
2982 test "$ac_cv_exeext" = no && ac_cv_exeext=
2984 else
2985 ac_file=''
2988 { $as_echo "$as_me:$LINENO: result: $ac_file" >&5
2989 $as_echo "$ac_file" >&6; }
2990 if test -z "$ac_file"; then
2991 $as_echo "$as_me: failed program was:" >&5
2992 sed 's/^/| /' conftest.$ac_ext >&5
2994 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
2995 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2996 { { $as_echo "$as_me:$LINENO: error: C compiler cannot create executables
2997 See \`config.log' for more details." >&5
2998 $as_echo "$as_me: error: C compiler cannot create executables
2999 See \`config.log' for more details." >&2;}
3000 { (exit 77); exit 77; }; }; }
3003 ac_exeext=$ac_cv_exeext
3005 # Check that the compiler produces executables we can run. If not, either
3006 # the compiler is broken, or we cross compile.
3007 { $as_echo "$as_me:$LINENO: checking whether the C compiler works" >&5
3008 $as_echo_n "checking whether the C compiler works... " >&6; }
3009 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3010 # If not cross compiling, check that we can run a simple program.
3011 if test "$cross_compiling" != yes; then
3012 if { ac_try='./$ac_file'
3013 { (case "(($ac_try" in
3014 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3015 *) ac_try_echo=$ac_try;;
3016 esac
3017 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3018 $as_echo "$ac_try_echo") >&5
3019 (eval "$ac_try") 2>&5
3020 ac_status=$?
3021 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3022 (exit $ac_status); }; }; then
3023 cross_compiling=no
3024 else
3025 if test "$cross_compiling" = maybe; then
3026 cross_compiling=yes
3027 else
3028 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3029 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3030 { { $as_echo "$as_me:$LINENO: error: cannot run C compiled programs.
3031 If you meant to cross compile, use \`--host'.
3032 See \`config.log' for more details." >&5
3033 $as_echo "$as_me: error: cannot run C compiled programs.
3034 If you meant to cross compile, use \`--host'.
3035 See \`config.log' for more details." >&2;}
3036 { (exit 1); exit 1; }; }; }
3040 { $as_echo "$as_me:$LINENO: result: yes" >&5
3041 $as_echo "yes" >&6; }
3043 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3044 ac_clean_files=$ac_clean_files_save
3045 # Check that the compiler produces executables we can run. If not, either
3046 # the compiler is broken, or we cross compile.
3047 { $as_echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
3048 $as_echo_n "checking whether we are cross compiling... " >&6; }
3049 { $as_echo "$as_me:$LINENO: result: $cross_compiling" >&5
3050 $as_echo "$cross_compiling" >&6; }
3052 { $as_echo "$as_me:$LINENO: checking for suffix of executables" >&5
3053 $as_echo_n "checking for suffix of executables... " >&6; }
3054 if { (ac_try="$ac_link"
3055 case "(($ac_try" in
3056 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3057 *) ac_try_echo=$ac_try;;
3058 esac
3059 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3060 $as_echo "$ac_try_echo") >&5
3061 (eval "$ac_link") 2>&5
3062 ac_status=$?
3063 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3064 (exit $ac_status); }; then
3065 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3066 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3067 # work properly (i.e., refer to `conftest.exe'), while it won't with
3068 # `rm'.
3069 for ac_file in conftest.exe conftest conftest.*; do
3070 test -f "$ac_file" || continue
3071 case $ac_file in
3072 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3073 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3074 break;;
3075 * ) break;;
3076 esac
3077 done
3078 else
3079 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3080 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3081 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3082 See \`config.log' for more details." >&5
3083 $as_echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3084 See \`config.log' for more details." >&2;}
3085 { (exit 1); exit 1; }; }; }
3088 rm -f conftest$ac_cv_exeext
3089 { $as_echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
3090 $as_echo "$ac_cv_exeext" >&6; }
3092 rm -f conftest.$ac_ext
3093 EXEEXT=$ac_cv_exeext
3094 ac_exeext=$EXEEXT
3095 { $as_echo "$as_me:$LINENO: checking for suffix of object files" >&5
3096 $as_echo_n "checking for suffix of object files... " >&6; }
3097 if test "${ac_cv_objext+set}" = set; then
3098 $as_echo_n "(cached) " >&6
3099 else
3100 cat >conftest.$ac_ext <<_ACEOF
3101 /* confdefs.h. */
3102 _ACEOF
3103 cat confdefs.h >>conftest.$ac_ext
3104 cat >>conftest.$ac_ext <<_ACEOF
3105 /* end confdefs.h. */
3108 main ()
3112 return 0;
3114 _ACEOF
3115 rm -f conftest.o conftest.obj
3116 if { (ac_try="$ac_compile"
3117 case "(($ac_try" in
3118 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3119 *) ac_try_echo=$ac_try;;
3120 esac
3121 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3122 $as_echo "$ac_try_echo") >&5
3123 (eval "$ac_compile") 2>&5
3124 ac_status=$?
3125 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3126 (exit $ac_status); }; then
3127 for ac_file in conftest.o conftest.obj conftest.*; do
3128 test -f "$ac_file" || continue;
3129 case $ac_file in
3130 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3131 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3132 break;;
3133 esac
3134 done
3135 else
3136 $as_echo "$as_me: failed program was:" >&5
3137 sed 's/^/| /' conftest.$ac_ext >&5
3139 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3140 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3141 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3142 See \`config.log' for more details." >&5
3143 $as_echo "$as_me: error: cannot compute suffix of object files: cannot compile
3144 See \`config.log' for more details." >&2;}
3145 { (exit 1); exit 1; }; }; }
3148 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3150 { $as_echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
3151 $as_echo "$ac_cv_objext" >&6; }
3152 OBJEXT=$ac_cv_objext
3153 ac_objext=$OBJEXT
3154 { $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
3155 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3156 if test "${ac_cv_c_compiler_gnu+set}" = set; then
3157 $as_echo_n "(cached) " >&6
3158 else
3159 cat >conftest.$ac_ext <<_ACEOF
3160 /* confdefs.h. */
3161 _ACEOF
3162 cat confdefs.h >>conftest.$ac_ext
3163 cat >>conftest.$ac_ext <<_ACEOF
3164 /* end confdefs.h. */
3167 main ()
3169 #ifndef __GNUC__
3170 choke me
3171 #endif
3174 return 0;
3176 _ACEOF
3177 rm -f conftest.$ac_objext
3178 if { (ac_try="$ac_compile"
3179 case "(($ac_try" in
3180 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3181 *) ac_try_echo=$ac_try;;
3182 esac
3183 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3184 $as_echo "$ac_try_echo") >&5
3185 (eval "$ac_compile") 2>conftest.er1
3186 ac_status=$?
3187 grep -v '^ *+' conftest.er1 >conftest.err
3188 rm -f conftest.er1
3189 cat conftest.err >&5
3190 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3191 (exit $ac_status); } && {
3192 test -z "$ac_c_werror_flag" ||
3193 test ! -s conftest.err
3194 } && test -s conftest.$ac_objext; then
3195 ac_compiler_gnu=yes
3196 else
3197 $as_echo "$as_me: failed program was:" >&5
3198 sed 's/^/| /' conftest.$ac_ext >&5
3200 ac_compiler_gnu=no
3203 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3204 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3207 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
3208 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3209 if test $ac_compiler_gnu = yes; then
3210 GCC=yes
3211 else
3212 GCC=
3214 ac_test_CFLAGS=${CFLAGS+set}
3215 ac_save_CFLAGS=$CFLAGS
3216 { $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
3217 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3218 if test "${ac_cv_prog_cc_g+set}" = set; then
3219 $as_echo_n "(cached) " >&6
3220 else
3221 ac_save_c_werror_flag=$ac_c_werror_flag
3222 ac_c_werror_flag=yes
3223 ac_cv_prog_cc_g=no
3224 CFLAGS="-g"
3225 cat >conftest.$ac_ext <<_ACEOF
3226 /* confdefs.h. */
3227 _ACEOF
3228 cat confdefs.h >>conftest.$ac_ext
3229 cat >>conftest.$ac_ext <<_ACEOF
3230 /* end confdefs.h. */
3233 main ()
3237 return 0;
3239 _ACEOF
3240 rm -f conftest.$ac_objext
3241 if { (ac_try="$ac_compile"
3242 case "(($ac_try" in
3243 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3244 *) ac_try_echo=$ac_try;;
3245 esac
3246 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3247 $as_echo "$ac_try_echo") >&5
3248 (eval "$ac_compile") 2>conftest.er1
3249 ac_status=$?
3250 grep -v '^ *+' conftest.er1 >conftest.err
3251 rm -f conftest.er1
3252 cat conftest.err >&5
3253 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3254 (exit $ac_status); } && {
3255 test -z "$ac_c_werror_flag" ||
3256 test ! -s conftest.err
3257 } && test -s conftest.$ac_objext; then
3258 ac_cv_prog_cc_g=yes
3259 else
3260 $as_echo "$as_me: failed program was:" >&5
3261 sed 's/^/| /' conftest.$ac_ext >&5
3263 CFLAGS=""
3264 cat >conftest.$ac_ext <<_ACEOF
3265 /* confdefs.h. */
3266 _ACEOF
3267 cat confdefs.h >>conftest.$ac_ext
3268 cat >>conftest.$ac_ext <<_ACEOF
3269 /* end confdefs.h. */
3272 main ()
3276 return 0;
3278 _ACEOF
3279 rm -f conftest.$ac_objext
3280 if { (ac_try="$ac_compile"
3281 case "(($ac_try" in
3282 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3283 *) ac_try_echo=$ac_try;;
3284 esac
3285 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3286 $as_echo "$ac_try_echo") >&5
3287 (eval "$ac_compile") 2>conftest.er1
3288 ac_status=$?
3289 grep -v '^ *+' conftest.er1 >conftest.err
3290 rm -f conftest.er1
3291 cat conftest.err >&5
3292 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3293 (exit $ac_status); } && {
3294 test -z "$ac_c_werror_flag" ||
3295 test ! -s conftest.err
3296 } && test -s conftest.$ac_objext; then
3298 else
3299 $as_echo "$as_me: failed program was:" >&5
3300 sed 's/^/| /' conftest.$ac_ext >&5
3302 ac_c_werror_flag=$ac_save_c_werror_flag
3303 CFLAGS="-g"
3304 cat >conftest.$ac_ext <<_ACEOF
3305 /* confdefs.h. */
3306 _ACEOF
3307 cat confdefs.h >>conftest.$ac_ext
3308 cat >>conftest.$ac_ext <<_ACEOF
3309 /* end confdefs.h. */
3312 main ()
3316 return 0;
3318 _ACEOF
3319 rm -f conftest.$ac_objext
3320 if { (ac_try="$ac_compile"
3321 case "(($ac_try" in
3322 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3323 *) ac_try_echo=$ac_try;;
3324 esac
3325 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3326 $as_echo "$ac_try_echo") >&5
3327 (eval "$ac_compile") 2>conftest.er1
3328 ac_status=$?
3329 grep -v '^ *+' conftest.er1 >conftest.err
3330 rm -f conftest.er1
3331 cat conftest.err >&5
3332 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3333 (exit $ac_status); } && {
3334 test -z "$ac_c_werror_flag" ||
3335 test ! -s conftest.err
3336 } && test -s conftest.$ac_objext; then
3337 ac_cv_prog_cc_g=yes
3338 else
3339 $as_echo "$as_me: failed program was:" >&5
3340 sed 's/^/| /' conftest.$ac_ext >&5
3345 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3348 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3351 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3352 ac_c_werror_flag=$ac_save_c_werror_flag
3354 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
3355 $as_echo "$ac_cv_prog_cc_g" >&6; }
3356 if test "$ac_test_CFLAGS" = set; then
3357 CFLAGS=$ac_save_CFLAGS
3358 elif test $ac_cv_prog_cc_g = yes; then
3359 if test "$GCC" = yes; then
3360 CFLAGS="-g -O2"
3361 else
3362 CFLAGS="-g"
3364 else
3365 if test "$GCC" = yes; then
3366 CFLAGS="-O2"
3367 else
3368 CFLAGS=
3371 { $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
3372 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3373 if test "${ac_cv_prog_cc_c89+set}" = set; then
3374 $as_echo_n "(cached) " >&6
3375 else
3376 ac_cv_prog_cc_c89=no
3377 ac_save_CC=$CC
3378 cat >conftest.$ac_ext <<_ACEOF
3379 /* confdefs.h. */
3380 _ACEOF
3381 cat confdefs.h >>conftest.$ac_ext
3382 cat >>conftest.$ac_ext <<_ACEOF
3383 /* end confdefs.h. */
3384 #include <stdarg.h>
3385 #include <stdio.h>
3386 #include <sys/types.h>
3387 #include <sys/stat.h>
3388 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3389 struct buf { int x; };
3390 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3391 static char *e (p, i)
3392 char **p;
3393 int i;
3395 return p[i];
3397 static char *f (char * (*g) (char **, int), char **p, ...)
3399 char *s;
3400 va_list v;
3401 va_start (v,p);
3402 s = g (p, va_arg (v,int));
3403 va_end (v);
3404 return s;
3407 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3408 function prototypes and stuff, but not '\xHH' hex character constants.
3409 These don't provoke an error unfortunately, instead are silently treated
3410 as 'x'. The following induces an error, until -std is added to get
3411 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3412 array size at least. It's necessary to write '\x00'==0 to get something
3413 that's true only with -std. */
3414 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3416 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3417 inside strings and character constants. */
3418 #define FOO(x) 'x'
3419 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3421 int test (int i, double x);
3422 struct s1 {int (*f) (int a);};
3423 struct s2 {int (*f) (double a);};
3424 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3425 int argc;
3426 char **argv;
3428 main ()
3430 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3432 return 0;
3434 _ACEOF
3435 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3436 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3438 CC="$ac_save_CC $ac_arg"
3439 rm -f conftest.$ac_objext
3440 if { (ac_try="$ac_compile"
3441 case "(($ac_try" in
3442 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3443 *) ac_try_echo=$ac_try;;
3444 esac
3445 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3446 $as_echo "$ac_try_echo") >&5
3447 (eval "$ac_compile") 2>conftest.er1
3448 ac_status=$?
3449 grep -v '^ *+' conftest.er1 >conftest.err
3450 rm -f conftest.er1
3451 cat conftest.err >&5
3452 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3453 (exit $ac_status); } && {
3454 test -z "$ac_c_werror_flag" ||
3455 test ! -s conftest.err
3456 } && test -s conftest.$ac_objext; then
3457 ac_cv_prog_cc_c89=$ac_arg
3458 else
3459 $as_echo "$as_me: failed program was:" >&5
3460 sed 's/^/| /' conftest.$ac_ext >&5
3465 rm -f core conftest.err conftest.$ac_objext
3466 test "x$ac_cv_prog_cc_c89" != "xno" && break
3467 done
3468 rm -f conftest.$ac_ext
3469 CC=$ac_save_CC
3472 # AC_CACHE_VAL
3473 case "x$ac_cv_prog_cc_c89" in
3475 { $as_echo "$as_me:$LINENO: result: none needed" >&5
3476 $as_echo "none needed" >&6; } ;;
3477 xno)
3478 { $as_echo "$as_me:$LINENO: result: unsupported" >&5
3479 $as_echo "unsupported" >&6; } ;;
3481 CC="$CC $ac_cv_prog_cc_c89"
3482 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
3483 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3484 esac
3487 ac_ext=c
3488 ac_cpp='$CPP $CPPFLAGS'
3489 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3490 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3491 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3492 DEPDIR="${am__leading_dot}deps"
3494 ac_config_commands="$ac_config_commands depfiles"
3497 am_make=${MAKE-make}
3498 cat > confinc << 'END'
3499 am__doit:
3500 @echo done
3501 .PHONY: am__doit
3503 # If we don't find an include directive, just comment out the code.
3504 { $as_echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5
3505 $as_echo_n "checking for style of include used by $am_make... " >&6; }
3506 am__include="#"
3507 am__quote=
3508 _am_result=none
3509 # First try GNU make style include.
3510 echo "include confinc" > confmf
3511 # We grep out `Entering directory' and `Leaving directory'
3512 # messages which can occur if `w' ends up in MAKEFLAGS.
3513 # In particular we don't look at `^make:' because GNU make might
3514 # be invoked under some other name (usually "gmake"), in which
3515 # case it prints its new name instead of `make'.
3516 if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
3517 am__include=include
3518 am__quote=
3519 _am_result=GNU
3521 # Now try BSD make style include.
3522 if test "$am__include" = "#"; then
3523 echo '.include "confinc"' > confmf
3524 if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
3525 am__include=.include
3526 am__quote="\""
3527 _am_result=BSD
3532 { $as_echo "$as_me:$LINENO: result: $_am_result" >&5
3533 $as_echo "$_am_result" >&6; }
3534 rm -f confinc confmf
3536 # Check whether --enable-dependency-tracking was given.
3537 if test "${enable_dependency_tracking+set}" = set; then
3538 enableval=$enable_dependency_tracking;
3541 if test "x$enable_dependency_tracking" != xno; then
3542 am_depcomp="$ac_aux_dir/depcomp"
3543 AMDEPBACKSLASH='\'
3545 if test "x$enable_dependency_tracking" != xno; then
3546 AMDEP_TRUE=
3547 AMDEP_FALSE='#'
3548 else
3549 AMDEP_TRUE='#'
3550 AMDEP_FALSE=
3555 depcc="$CC" am_compiler_list=
3557 { $as_echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
3558 $as_echo_n "checking dependency style of $depcc... " >&6; }
3559 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
3560 $as_echo_n "(cached) " >&6
3561 else
3562 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
3563 # We make a subdir and do the tests there. Otherwise we can end up
3564 # making bogus files that we don't know about and never remove. For
3565 # instance it was reported that on HP-UX the gcc test will end up
3566 # making a dummy file named `D' -- because `-MD' means `put the output
3567 # in D'.
3568 mkdir conftest.dir
3569 # Copy depcomp to subdir because otherwise we won't find it if we're
3570 # using a relative directory.
3571 cp "$am_depcomp" conftest.dir
3572 cd conftest.dir
3573 # We will build objects and dependencies in a subdirectory because
3574 # it helps to detect inapplicable dependency modes. For instance
3575 # both Tru64's cc and ICC support -MD to output dependencies as a
3576 # side effect of compilation, but ICC will put the dependencies in
3577 # the current directory while Tru64 will put them in the object
3578 # directory.
3579 mkdir sub
3581 am_cv_CC_dependencies_compiler_type=none
3582 if test "$am_compiler_list" = ""; then
3583 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
3585 for depmode in $am_compiler_list; do
3586 # Setup a source with many dependencies, because some compilers
3587 # like to wrap large dependency lists on column 80 (with \), and
3588 # we should not choose a depcomp mode which is confused by this.
3590 # We need to recreate these files for each test, as the compiler may
3591 # overwrite some of them when testing with obscure command lines.
3592 # This happens at least with the AIX C compiler.
3593 : > sub/conftest.c
3594 for i in 1 2 3 4 5 6; do
3595 echo '#include "conftst'$i'.h"' >> sub/conftest.c
3596 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
3597 # Solaris 8's {/usr,}/bin/sh.
3598 touch sub/conftst$i.h
3599 done
3600 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
3602 case $depmode in
3603 nosideeffect)
3604 # after this tag, mechanisms are not by side-effect, so they'll
3605 # only be used when explicitly requested
3606 if test "x$enable_dependency_tracking" = xyes; then
3607 continue
3608 else
3609 break
3612 none) break ;;
3613 esac
3614 # We check with `-c' and `-o' for the sake of the "dashmstdout"
3615 # mode. It turns out that the SunPro C++ compiler does not properly
3616 # handle `-M -o', and we need to detect this.
3617 if depmode=$depmode \
3618 source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
3619 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
3620 $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
3621 >/dev/null 2>conftest.err &&
3622 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
3623 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
3624 grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
3625 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
3626 # icc doesn't choke on unknown options, it will just issue warnings
3627 # or remarks (even with -Werror). So we grep stderr for any message
3628 # that says an option was ignored or not supported.
3629 # When given -MP, icc 7.0 and 7.1 complain thusly:
3630 # icc: Command line warning: ignoring option '-M'; no argument required
3631 # The diagnosis changed in icc 8.0:
3632 # icc: Command line remark: option '-MP' not supported
3633 if (grep 'ignoring option' conftest.err ||
3634 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
3635 am_cv_CC_dependencies_compiler_type=$depmode
3636 break
3639 done
3641 cd ..
3642 rm -rf conftest.dir
3643 else
3644 am_cv_CC_dependencies_compiler_type=none
3648 { $as_echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
3649 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
3650 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
3653 test "x$enable_dependency_tracking" != xno \
3654 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
3655 am__fastdepCC_TRUE=
3656 am__fastdepCC_FALSE='#'
3657 else
3658 am__fastdepCC_TRUE='#'
3659 am__fastdepCC_FALSE=
3663 ac_ext=c
3664 ac_cpp='$CPP $CPPFLAGS'
3665 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3666 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3667 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3668 { $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
3669 $as_echo_n "checking how to run the C preprocessor... " >&6; }
3670 # On Suns, sometimes $CPP names a directory.
3671 if test -n "$CPP" && test -d "$CPP"; then
3672 CPP=
3674 if test -z "$CPP"; then
3675 if test "${ac_cv_prog_CPP+set}" = set; then
3676 $as_echo_n "(cached) " >&6
3677 else
3678 # Double quotes because CPP needs to be expanded
3679 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3681 ac_preproc_ok=false
3682 for ac_c_preproc_warn_flag in '' yes
3684 # Use a header file that comes with gcc, so configuring glibc
3685 # with a fresh cross-compiler works.
3686 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3687 # <limits.h> exists even on freestanding compilers.
3688 # On the NeXT, cc -E runs the code through the compiler's parser,
3689 # not just through cpp. "Syntax error" is here to catch this case.
3690 cat >conftest.$ac_ext <<_ACEOF
3691 /* confdefs.h. */
3692 _ACEOF
3693 cat confdefs.h >>conftest.$ac_ext
3694 cat >>conftest.$ac_ext <<_ACEOF
3695 /* end confdefs.h. */
3696 #ifdef __STDC__
3697 # include <limits.h>
3698 #else
3699 # include <assert.h>
3700 #endif
3701 Syntax error
3702 _ACEOF
3703 if { (ac_try="$ac_cpp conftest.$ac_ext"
3704 case "(($ac_try" in
3705 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3706 *) ac_try_echo=$ac_try;;
3707 esac
3708 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3709 $as_echo "$ac_try_echo") >&5
3710 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
3711 ac_status=$?
3712 grep -v '^ *+' conftest.er1 >conftest.err
3713 rm -f conftest.er1
3714 cat conftest.err >&5
3715 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3716 (exit $ac_status); } >/dev/null && {
3717 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3718 test ! -s conftest.err
3719 }; then
3721 else
3722 $as_echo "$as_me: failed program was:" >&5
3723 sed 's/^/| /' conftest.$ac_ext >&5
3725 # Broken: fails on valid input.
3726 continue
3729 rm -f conftest.err conftest.$ac_ext
3731 # OK, works on sane cases. Now check whether nonexistent headers
3732 # can be detected and how.
3733 cat >conftest.$ac_ext <<_ACEOF
3734 /* confdefs.h. */
3735 _ACEOF
3736 cat confdefs.h >>conftest.$ac_ext
3737 cat >>conftest.$ac_ext <<_ACEOF
3738 /* end confdefs.h. */
3739 #include <ac_nonexistent.h>
3740 _ACEOF
3741 if { (ac_try="$ac_cpp conftest.$ac_ext"
3742 case "(($ac_try" in
3743 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3744 *) ac_try_echo=$ac_try;;
3745 esac
3746 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3747 $as_echo "$ac_try_echo") >&5
3748 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
3749 ac_status=$?
3750 grep -v '^ *+' conftest.er1 >conftest.err
3751 rm -f conftest.er1
3752 cat conftest.err >&5
3753 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3754 (exit $ac_status); } >/dev/null && {
3755 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3756 test ! -s conftest.err
3757 }; then
3758 # Broken: success on invalid input.
3759 continue
3760 else
3761 $as_echo "$as_me: failed program was:" >&5
3762 sed 's/^/| /' conftest.$ac_ext >&5
3764 # Passes both tests.
3765 ac_preproc_ok=:
3766 break
3769 rm -f conftest.err conftest.$ac_ext
3771 done
3772 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3773 rm -f conftest.err conftest.$ac_ext
3774 if $ac_preproc_ok; then
3775 break
3778 done
3779 ac_cv_prog_CPP=$CPP
3782 CPP=$ac_cv_prog_CPP
3783 else
3784 ac_cv_prog_CPP=$CPP
3786 { $as_echo "$as_me:$LINENO: result: $CPP" >&5
3787 $as_echo "$CPP" >&6; }
3788 ac_preproc_ok=false
3789 for ac_c_preproc_warn_flag in '' yes
3791 # Use a header file that comes with gcc, so configuring glibc
3792 # with a fresh cross-compiler works.
3793 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3794 # <limits.h> exists even on freestanding compilers.
3795 # On the NeXT, cc -E runs the code through the compiler's parser,
3796 # not just through cpp. "Syntax error" is here to catch this case.
3797 cat >conftest.$ac_ext <<_ACEOF
3798 /* confdefs.h. */
3799 _ACEOF
3800 cat confdefs.h >>conftest.$ac_ext
3801 cat >>conftest.$ac_ext <<_ACEOF
3802 /* end confdefs.h. */
3803 #ifdef __STDC__
3804 # include <limits.h>
3805 #else
3806 # include <assert.h>
3807 #endif
3808 Syntax error
3809 _ACEOF
3810 if { (ac_try="$ac_cpp conftest.$ac_ext"
3811 case "(($ac_try" in
3812 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3813 *) ac_try_echo=$ac_try;;
3814 esac
3815 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3816 $as_echo "$ac_try_echo") >&5
3817 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
3818 ac_status=$?
3819 grep -v '^ *+' conftest.er1 >conftest.err
3820 rm -f conftest.er1
3821 cat conftest.err >&5
3822 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3823 (exit $ac_status); } >/dev/null && {
3824 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3825 test ! -s conftest.err
3826 }; then
3828 else
3829 $as_echo "$as_me: failed program was:" >&5
3830 sed 's/^/| /' conftest.$ac_ext >&5
3832 # Broken: fails on valid input.
3833 continue
3836 rm -f conftest.err conftest.$ac_ext
3838 # OK, works on sane cases. Now check whether nonexistent headers
3839 # can be detected and how.
3840 cat >conftest.$ac_ext <<_ACEOF
3841 /* confdefs.h. */
3842 _ACEOF
3843 cat confdefs.h >>conftest.$ac_ext
3844 cat >>conftest.$ac_ext <<_ACEOF
3845 /* end confdefs.h. */
3846 #include <ac_nonexistent.h>
3847 _ACEOF
3848 if { (ac_try="$ac_cpp conftest.$ac_ext"
3849 case "(($ac_try" in
3850 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3851 *) ac_try_echo=$ac_try;;
3852 esac
3853 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3854 $as_echo "$ac_try_echo") >&5
3855 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
3856 ac_status=$?
3857 grep -v '^ *+' conftest.er1 >conftest.err
3858 rm -f conftest.er1
3859 cat conftest.err >&5
3860 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3861 (exit $ac_status); } >/dev/null && {
3862 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3863 test ! -s conftest.err
3864 }; then
3865 # Broken: success on invalid input.
3866 continue
3867 else
3868 $as_echo "$as_me: failed program was:" >&5
3869 sed 's/^/| /' conftest.$ac_ext >&5
3871 # Passes both tests.
3872 ac_preproc_ok=:
3873 break
3876 rm -f conftest.err conftest.$ac_ext
3878 done
3879 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3880 rm -f conftest.err conftest.$ac_ext
3881 if $ac_preproc_ok; then
3883 else
3884 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3885 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3886 { { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
3887 See \`config.log' for more details." >&5
3888 $as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
3889 See \`config.log' for more details." >&2;}
3890 { (exit 1); exit 1; }; }; }
3893 ac_ext=c
3894 ac_cpp='$CPP $CPPFLAGS'
3895 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3896 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3897 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3900 # Make sure we can run config.sub.
3901 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
3902 { { $as_echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
3903 $as_echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
3904 { (exit 1); exit 1; }; }
3906 { $as_echo "$as_me:$LINENO: checking build system type" >&5
3907 $as_echo_n "checking build system type... " >&6; }
3908 if test "${ac_cv_build+set}" = set; then
3909 $as_echo_n "(cached) " >&6
3910 else
3911 ac_build_alias=$build_alias
3912 test "x$ac_build_alias" = x &&
3913 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
3914 test "x$ac_build_alias" = x &&
3915 { { $as_echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
3916 $as_echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
3917 { (exit 1); exit 1; }; }
3918 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
3919 { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
3920 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
3921 { (exit 1); exit 1; }; }
3924 { $as_echo "$as_me:$LINENO: result: $ac_cv_build" >&5
3925 $as_echo "$ac_cv_build" >&6; }
3926 case $ac_cv_build in
3927 *-*-*) ;;
3928 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
3929 $as_echo "$as_me: error: invalid value of canonical build" >&2;}
3930 { (exit 1); exit 1; }; };;
3931 esac
3932 build=$ac_cv_build
3933 ac_save_IFS=$IFS; IFS='-'
3934 set x $ac_cv_build
3935 shift
3936 build_cpu=$1
3937 build_vendor=$2
3938 shift; shift
3939 # Remember, the first character of IFS is used to create $*,
3940 # except with old shells:
3941 build_os=$*
3942 IFS=$ac_save_IFS
3943 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
3946 { $as_echo "$as_me:$LINENO: checking host system type" >&5
3947 $as_echo_n "checking host system type... " >&6; }
3948 if test "${ac_cv_host+set}" = set; then
3949 $as_echo_n "(cached) " >&6
3950 else
3951 if test "x$host_alias" = x; then
3952 ac_cv_host=$ac_cv_build
3953 else
3954 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
3955 { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
3956 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
3957 { (exit 1); exit 1; }; }
3961 { $as_echo "$as_me:$LINENO: result: $ac_cv_host" >&5
3962 $as_echo "$ac_cv_host" >&6; }
3963 case $ac_cv_host in
3964 *-*-*) ;;
3965 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
3966 $as_echo "$as_me: error: invalid value of canonical host" >&2;}
3967 { (exit 1); exit 1; }; };;
3968 esac
3969 host=$ac_cv_host
3970 ac_save_IFS=$IFS; IFS='-'
3971 set x $ac_cv_host
3972 shift
3973 host_cpu=$1
3974 host_vendor=$2
3975 shift; shift
3976 # Remember, the first character of IFS is used to create $*,
3977 # except with old shells:
3978 host_os=$*
3979 IFS=$ac_save_IFS
3980 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
3983 { $as_echo "$as_me:$LINENO: checking host platform" >&5
3984 $as_echo_n "checking host platform... " >&6; }
3985 sv_cv_host="$host"
3986 case "$host_os" in
3987 linux | linux-*)
3988 kernelversion=`uname -r | sed -e 's/^\([0-9.]*\).*/\1/'`
3989 sv_cv_host=`echo $sv_cv_host | sed -e "s/linux/linux$kernelversion/"`
3991 esac
3992 cat > conftest.c << EOF
3993 #include <features.h>
3994 #ifdef __GNU_LIBRARY__
3995 Version __GLIBC__ . __GLIBC_MINOR__
3996 #endif
3998 glibcversion=`$CPP $CPPFLAGS conftest.c 2>/dev/null | grep Version | sed -e 's/Version//' -e 's/ //g'`
3999 if test -n "$glibcversion"; then
4000 sv_cv_host="$sv_cv_host-glibc$glibcversion"
4002 { $as_echo "$as_me:$LINENO: result: $sv_cv_host" >&5
4003 $as_echo "$sv_cv_host" >&6; }
4004 PLATFORM="$sv_cv_host"
4007 # Find a good install program. We prefer a C program (faster),
4008 # so one script is as good as another. But avoid the broken or
4009 # incompatible versions:
4010 # SysV /etc/install, /usr/sbin/install
4011 # SunOS /usr/etc/install
4012 # IRIX /sbin/install
4013 # AIX /bin/install
4014 # AmigaOS /C/install, which installs bootblocks on floppy discs
4015 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
4016 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
4017 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
4018 # OS/2's system install, which has a completely different semantic
4019 # ./install, which can be erroneously created by make from ./install.sh.
4020 # Reject install programs that cannot install multiple files.
4021 { $as_echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
4022 $as_echo_n "checking for a BSD-compatible install... " >&6; }
4023 if test -z "$INSTALL"; then
4024 if test "${ac_cv_path_install+set}" = set; then
4025 $as_echo_n "(cached) " >&6
4026 else
4027 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4028 for as_dir in $PATH
4030 IFS=$as_save_IFS
4031 test -z "$as_dir" && as_dir=.
4032 # Account for people who put trailing slashes in PATH elements.
4033 case $as_dir/ in
4034 ./ | .// | /cC/* | \
4035 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
4036 ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
4037 /usr/ucb/* ) ;;
4039 # OSF1 and SCO ODT 3.0 have their own names for install.
4040 # Don't use installbsd from OSF since it installs stuff as root
4041 # by default.
4042 for ac_prog in ginstall scoinst install; do
4043 for ac_exec_ext in '' $ac_executable_extensions; do
4044 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
4045 if test $ac_prog = install &&
4046 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4047 # AIX install. It has an incompatible calling convention.
4049 elif test $ac_prog = install &&
4050 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4051 # program-specific install script used by HP pwplus--don't use.
4053 else
4054 rm -rf conftest.one conftest.two conftest.dir
4055 echo one > conftest.one
4056 echo two > conftest.two
4057 mkdir conftest.dir
4058 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
4059 test -s conftest.one && test -s conftest.two &&
4060 test -s conftest.dir/conftest.one &&
4061 test -s conftest.dir/conftest.two
4062 then
4063 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
4064 break 3
4068 done
4069 done
4071 esac
4073 done
4074 IFS=$as_save_IFS
4076 rm -rf conftest.one conftest.two conftest.dir
4079 if test "${ac_cv_path_install+set}" = set; then
4080 INSTALL=$ac_cv_path_install
4081 else
4082 # As a last resort, use the slow shell script. Don't cache a
4083 # value for INSTALL within a source directory, because that will
4084 # break other packages using the cache if that directory is
4085 # removed, or if the value is a relative name.
4086 INSTALL=$ac_install_sh
4089 { $as_echo "$as_me:$LINENO: result: $INSTALL" >&5
4090 $as_echo "$INSTALL" >&6; }
4092 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
4093 # It thinks the first close brace ends the variable substitution.
4094 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
4096 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
4098 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
4101 case `pwd` in
4102 *\ * | *\ *)
4103 { $as_echo "$as_me:$LINENO: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
4104 $as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
4105 esac
4109 macro_version='2.2.6'
4110 macro_revision='1.3012'
4124 ltmain="$ac_aux_dir/ltmain.sh"
4126 { $as_echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5
4127 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
4128 if test "${ac_cv_path_SED+set}" = set; then
4129 $as_echo_n "(cached) " >&6
4130 else
4131 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
4132 for ac_i in 1 2 3 4 5 6 7; do
4133 ac_script="$ac_script$as_nl$ac_script"
4134 done
4135 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
4136 $as_unset ac_script || ac_script=
4137 if test -z "$SED"; then
4138 ac_path_SED_found=false
4139 # Loop through the user's path and test for each of PROGNAME-LIST
4140 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4141 for as_dir in $PATH
4143 IFS=$as_save_IFS
4144 test -z "$as_dir" && as_dir=.
4145 for ac_prog in sed gsed; do
4146 for ac_exec_ext in '' $ac_executable_extensions; do
4147 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
4148 { test -f "$ac_path_SED" && $as_test_x "$ac_path_SED"; } || continue
4149 # Check for GNU ac_path_SED and select it if it is found.
4150 # Check for GNU $ac_path_SED
4151 case `"$ac_path_SED" --version 2>&1` in
4152 *GNU*)
4153 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
4155 ac_count=0
4156 $as_echo_n 0123456789 >"conftest.in"
4157 while :
4159 cat "conftest.in" "conftest.in" >"conftest.tmp"
4160 mv "conftest.tmp" "conftest.in"
4161 cp "conftest.in" "conftest.nl"
4162 $as_echo '' >> "conftest.nl"
4163 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
4164 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4165 ac_count=`expr $ac_count + 1`
4166 if test $ac_count -gt ${ac_path_SED_max-0}; then
4167 # Best one so far, save it but keep looking for a better one
4168 ac_cv_path_SED="$ac_path_SED"
4169 ac_path_SED_max=$ac_count
4171 # 10*(2^10) chars as input seems more than enough
4172 test $ac_count -gt 10 && break
4173 done
4174 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4175 esac
4177 $ac_path_SED_found && break 3
4178 done
4179 done
4180 done
4181 IFS=$as_save_IFS
4182 if test -z "$ac_cv_path_SED"; then
4183 { { $as_echo "$as_me:$LINENO: error: no acceptable sed could be found in \$PATH" >&5
4184 $as_echo "$as_me: error: no acceptable sed could be found in \$PATH" >&2;}
4185 { (exit 1); exit 1; }; }
4187 else
4188 ac_cv_path_SED=$SED
4192 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_SED" >&5
4193 $as_echo "$ac_cv_path_SED" >&6; }
4194 SED="$ac_cv_path_SED"
4195 rm -f conftest.sed
4197 test -z "$SED" && SED=sed
4198 Xsed="$SED -e 1s/^X//"
4210 { $as_echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
4211 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4212 if test "${ac_cv_path_GREP+set}" = set; then
4213 $as_echo_n "(cached) " >&6
4214 else
4215 if test -z "$GREP"; then
4216 ac_path_GREP_found=false
4217 # Loop through the user's path and test for each of PROGNAME-LIST
4218 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4219 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4221 IFS=$as_save_IFS
4222 test -z "$as_dir" && as_dir=.
4223 for ac_prog in grep ggrep; do
4224 for ac_exec_ext in '' $ac_executable_extensions; do
4225 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4226 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
4227 # Check for GNU ac_path_GREP and select it if it is found.
4228 # Check for GNU $ac_path_GREP
4229 case `"$ac_path_GREP" --version 2>&1` in
4230 *GNU*)
4231 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4233 ac_count=0
4234 $as_echo_n 0123456789 >"conftest.in"
4235 while :
4237 cat "conftest.in" "conftest.in" >"conftest.tmp"
4238 mv "conftest.tmp" "conftest.in"
4239 cp "conftest.in" "conftest.nl"
4240 $as_echo 'GREP' >> "conftest.nl"
4241 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4242 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4243 ac_count=`expr $ac_count + 1`
4244 if test $ac_count -gt ${ac_path_GREP_max-0}; then
4245 # Best one so far, save it but keep looking for a better one
4246 ac_cv_path_GREP="$ac_path_GREP"
4247 ac_path_GREP_max=$ac_count
4249 # 10*(2^10) chars as input seems more than enough
4250 test $ac_count -gt 10 && break
4251 done
4252 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4253 esac
4255 $ac_path_GREP_found && break 3
4256 done
4257 done
4258 done
4259 IFS=$as_save_IFS
4260 if test -z "$ac_cv_path_GREP"; then
4261 { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
4262 $as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
4263 { (exit 1); exit 1; }; }
4265 else
4266 ac_cv_path_GREP=$GREP
4270 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
4271 $as_echo "$ac_cv_path_GREP" >&6; }
4272 GREP="$ac_cv_path_GREP"
4275 { $as_echo "$as_me:$LINENO: checking for egrep" >&5
4276 $as_echo_n "checking for egrep... " >&6; }
4277 if test "${ac_cv_path_EGREP+set}" = set; then
4278 $as_echo_n "(cached) " >&6
4279 else
4280 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4281 then ac_cv_path_EGREP="$GREP -E"
4282 else
4283 if test -z "$EGREP"; then
4284 ac_path_EGREP_found=false
4285 # Loop through the user's path and test for each of PROGNAME-LIST
4286 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4287 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4289 IFS=$as_save_IFS
4290 test -z "$as_dir" && as_dir=.
4291 for ac_prog in egrep; do
4292 for ac_exec_ext in '' $ac_executable_extensions; do
4293 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4294 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
4295 # Check for GNU ac_path_EGREP and select it if it is found.
4296 # Check for GNU $ac_path_EGREP
4297 case `"$ac_path_EGREP" --version 2>&1` in
4298 *GNU*)
4299 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4301 ac_count=0
4302 $as_echo_n 0123456789 >"conftest.in"
4303 while :
4305 cat "conftest.in" "conftest.in" >"conftest.tmp"
4306 mv "conftest.tmp" "conftest.in"
4307 cp "conftest.in" "conftest.nl"
4308 $as_echo 'EGREP' >> "conftest.nl"
4309 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4310 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4311 ac_count=`expr $ac_count + 1`
4312 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4313 # Best one so far, save it but keep looking for a better one
4314 ac_cv_path_EGREP="$ac_path_EGREP"
4315 ac_path_EGREP_max=$ac_count
4317 # 10*(2^10) chars as input seems more than enough
4318 test $ac_count -gt 10 && break
4319 done
4320 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4321 esac
4323 $ac_path_EGREP_found && break 3
4324 done
4325 done
4326 done
4327 IFS=$as_save_IFS
4328 if test -z "$ac_cv_path_EGREP"; then
4329 { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
4330 $as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
4331 { (exit 1); exit 1; }; }
4333 else
4334 ac_cv_path_EGREP=$EGREP
4339 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
4340 $as_echo "$ac_cv_path_EGREP" >&6; }
4341 EGREP="$ac_cv_path_EGREP"
4344 { $as_echo "$as_me:$LINENO: checking for fgrep" >&5
4345 $as_echo_n "checking for fgrep... " >&6; }
4346 if test "${ac_cv_path_FGREP+set}" = set; then
4347 $as_echo_n "(cached) " >&6
4348 else
4349 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
4350 then ac_cv_path_FGREP="$GREP -F"
4351 else
4352 if test -z "$FGREP"; then
4353 ac_path_FGREP_found=false
4354 # Loop through the user's path and test for each of PROGNAME-LIST
4355 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4356 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4358 IFS=$as_save_IFS
4359 test -z "$as_dir" && as_dir=.
4360 for ac_prog in fgrep; do
4361 for ac_exec_ext in '' $ac_executable_extensions; do
4362 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
4363 { test -f "$ac_path_FGREP" && $as_test_x "$ac_path_FGREP"; } || continue
4364 # Check for GNU ac_path_FGREP and select it if it is found.
4365 # Check for GNU $ac_path_FGREP
4366 case `"$ac_path_FGREP" --version 2>&1` in
4367 *GNU*)
4368 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
4370 ac_count=0
4371 $as_echo_n 0123456789 >"conftest.in"
4372 while :
4374 cat "conftest.in" "conftest.in" >"conftest.tmp"
4375 mv "conftest.tmp" "conftest.in"
4376 cp "conftest.in" "conftest.nl"
4377 $as_echo 'FGREP' >> "conftest.nl"
4378 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
4379 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4380 ac_count=`expr $ac_count + 1`
4381 if test $ac_count -gt ${ac_path_FGREP_max-0}; then
4382 # Best one so far, save it but keep looking for a better one
4383 ac_cv_path_FGREP="$ac_path_FGREP"
4384 ac_path_FGREP_max=$ac_count
4386 # 10*(2^10) chars as input seems more than enough
4387 test $ac_count -gt 10 && break
4388 done
4389 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4390 esac
4392 $ac_path_FGREP_found && break 3
4393 done
4394 done
4395 done
4396 IFS=$as_save_IFS
4397 if test -z "$ac_cv_path_FGREP"; then
4398 { { $as_echo "$as_me:$LINENO: error: no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
4399 $as_echo "$as_me: error: no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
4400 { (exit 1); exit 1; }; }
4402 else
4403 ac_cv_path_FGREP=$FGREP
4408 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_FGREP" >&5
4409 $as_echo "$ac_cv_path_FGREP" >&6; }
4410 FGREP="$ac_cv_path_FGREP"
4413 test -z "$GREP" && GREP=grep
4433 # Check whether --with-gnu-ld was given.
4434 if test "${with_gnu_ld+set}" = set; then
4435 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
4436 else
4437 with_gnu_ld=no
4440 ac_prog=ld
4441 if test "$GCC" = yes; then
4442 # Check if gcc -print-prog-name=ld gives a path.
4443 { $as_echo "$as_me:$LINENO: checking for ld used by $CC" >&5
4444 $as_echo_n "checking for ld used by $CC... " >&6; }
4445 case $host in
4446 *-*-mingw*)
4447 # gcc leaves a trailing carriage return which upsets mingw
4448 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
4450 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
4451 esac
4452 case $ac_prog in
4453 # Accept absolute paths.
4454 [\\/]* | ?:[\\/]*)
4455 re_direlt='/[^/][^/]*/\.\./'
4456 # Canonicalize the pathname of ld
4457 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
4458 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
4459 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
4460 done
4461 test -z "$LD" && LD="$ac_prog"
4464 # If it fails, then pretend we aren't using GCC.
4465 ac_prog=ld
4468 # If it is relative, then search for the first ld in PATH.
4469 with_gnu_ld=unknown
4471 esac
4472 elif test "$with_gnu_ld" = yes; then
4473 { $as_echo "$as_me:$LINENO: checking for GNU ld" >&5
4474 $as_echo_n "checking for GNU ld... " >&6; }
4475 else
4476 { $as_echo "$as_me:$LINENO: checking for non-GNU ld" >&5
4477 $as_echo_n "checking for non-GNU ld... " >&6; }
4479 if test "${lt_cv_path_LD+set}" = set; then
4480 $as_echo_n "(cached) " >&6
4481 else
4482 if test -z "$LD"; then
4483 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4484 for ac_dir in $PATH; do
4485 IFS="$lt_save_ifs"
4486 test -z "$ac_dir" && ac_dir=.
4487 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
4488 lt_cv_path_LD="$ac_dir/$ac_prog"
4489 # Check to see if the program is GNU ld. I'd rather use --version,
4490 # but apparently some variants of GNU ld only accept -v.
4491 # Break only if it was the GNU/non-GNU ld that we prefer.
4492 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
4493 *GNU* | *'with BFD'*)
4494 test "$with_gnu_ld" != no && break
4497 test "$with_gnu_ld" != yes && break
4499 esac
4501 done
4502 IFS="$lt_save_ifs"
4503 else
4504 lt_cv_path_LD="$LD" # Let the user override the test with a path.
4508 LD="$lt_cv_path_LD"
4509 if test -n "$LD"; then
4510 { $as_echo "$as_me:$LINENO: result: $LD" >&5
4511 $as_echo "$LD" >&6; }
4512 else
4513 { $as_echo "$as_me:$LINENO: result: no" >&5
4514 $as_echo "no" >&6; }
4516 test -z "$LD" && { { $as_echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
4517 $as_echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
4518 { (exit 1); exit 1; }; }
4519 { $as_echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
4520 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
4521 if test "${lt_cv_prog_gnu_ld+set}" = set; then
4522 $as_echo_n "(cached) " >&6
4523 else
4524 # I'd rather use --version here, but apparently some GNU lds only accept -v.
4525 case `$LD -v 2>&1 </dev/null` in
4526 *GNU* | *'with BFD'*)
4527 lt_cv_prog_gnu_ld=yes
4530 lt_cv_prog_gnu_ld=no
4532 esac
4534 { $as_echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
4535 $as_echo "$lt_cv_prog_gnu_ld" >&6; }
4536 with_gnu_ld=$lt_cv_prog_gnu_ld
4546 { $as_echo "$as_me:$LINENO: checking for BSD- or MS-compatible name lister (nm)" >&5
4547 $as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
4548 if test "${lt_cv_path_NM+set}" = set; then
4549 $as_echo_n "(cached) " >&6
4550 else
4551 if test -n "$NM"; then
4552 # Let the user override the test.
4553 lt_cv_path_NM="$NM"
4554 else
4555 lt_nm_to_check="${ac_tool_prefix}nm"
4556 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
4557 lt_nm_to_check="$lt_nm_to_check nm"
4559 for lt_tmp_nm in $lt_nm_to_check; do
4560 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4561 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
4562 IFS="$lt_save_ifs"
4563 test -z "$ac_dir" && ac_dir=.
4564 tmp_nm="$ac_dir/$lt_tmp_nm"
4565 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
4566 # Check to see if the nm accepts a BSD-compat flag.
4567 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
4568 # nm: unknown option "B" ignored
4569 # Tru64's nm complains that /dev/null is an invalid object file
4570 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
4571 */dev/null* | *'Invalid file or object type'*)
4572 lt_cv_path_NM="$tmp_nm -B"
4573 break
4576 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
4577 */dev/null*)
4578 lt_cv_path_NM="$tmp_nm -p"
4579 break
4582 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
4583 continue # so that we can try to find one that supports BSD flags
4585 esac
4587 esac
4589 done
4590 IFS="$lt_save_ifs"
4591 done
4592 : ${lt_cv_path_NM=no}
4595 { $as_echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5
4596 $as_echo "$lt_cv_path_NM" >&6; }
4597 if test "$lt_cv_path_NM" != "no"; then
4598 NM="$lt_cv_path_NM"
4599 else
4600 # Didn't find any BSD compatible name lister, look for dumpbin.
4601 if test -n "$ac_tool_prefix"; then
4602 for ac_prog in "dumpbin -symbols" "link -dump -symbols"
4604 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4605 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4606 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
4607 $as_echo_n "checking for $ac_word... " >&6; }
4608 if test "${ac_cv_prog_DUMPBIN+set}" = set; then
4609 $as_echo_n "(cached) " >&6
4610 else
4611 if test -n "$DUMPBIN"; then
4612 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
4613 else
4614 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4615 for as_dir in $PATH
4617 IFS=$as_save_IFS
4618 test -z "$as_dir" && as_dir=.
4619 for ac_exec_ext in '' $ac_executable_extensions; do
4620 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4621 ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
4622 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4623 break 2
4625 done
4626 done
4627 IFS=$as_save_IFS
4631 DUMPBIN=$ac_cv_prog_DUMPBIN
4632 if test -n "$DUMPBIN"; then
4633 { $as_echo "$as_me:$LINENO: result: $DUMPBIN" >&5
4634 $as_echo "$DUMPBIN" >&6; }
4635 else
4636 { $as_echo "$as_me:$LINENO: result: no" >&5
4637 $as_echo "no" >&6; }
4641 test -n "$DUMPBIN" && break
4642 done
4644 if test -z "$DUMPBIN"; then
4645 ac_ct_DUMPBIN=$DUMPBIN
4646 for ac_prog in "dumpbin -symbols" "link -dump -symbols"
4648 # Extract the first word of "$ac_prog", so it can be a program name with args.
4649 set dummy $ac_prog; ac_word=$2
4650 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
4651 $as_echo_n "checking for $ac_word... " >&6; }
4652 if test "${ac_cv_prog_ac_ct_DUMPBIN+set}" = set; then
4653 $as_echo_n "(cached) " >&6
4654 else
4655 if test -n "$ac_ct_DUMPBIN"; then
4656 ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
4657 else
4658 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4659 for as_dir in $PATH
4661 IFS=$as_save_IFS
4662 test -z "$as_dir" && as_dir=.
4663 for ac_exec_ext in '' $ac_executable_extensions; do
4664 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4665 ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
4666 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4667 break 2
4669 done
4670 done
4671 IFS=$as_save_IFS
4675 ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
4676 if test -n "$ac_ct_DUMPBIN"; then
4677 { $as_echo "$as_me:$LINENO: result: $ac_ct_DUMPBIN" >&5
4678 $as_echo "$ac_ct_DUMPBIN" >&6; }
4679 else
4680 { $as_echo "$as_me:$LINENO: result: no" >&5
4681 $as_echo "no" >&6; }
4685 test -n "$ac_ct_DUMPBIN" && break
4686 done
4688 if test "x$ac_ct_DUMPBIN" = x; then
4689 DUMPBIN=":"
4690 else
4691 case $cross_compiling:$ac_tool_warned in
4692 yes:)
4693 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
4694 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4695 ac_tool_warned=yes ;;
4696 esac
4697 DUMPBIN=$ac_ct_DUMPBIN
4702 if test "$DUMPBIN" != ":"; then
4703 NM="$DUMPBIN"
4706 test -z "$NM" && NM=nm
4713 { $as_echo "$as_me:$LINENO: checking the name lister ($NM) interface" >&5
4714 $as_echo_n "checking the name lister ($NM) interface... " >&6; }
4715 if test "${lt_cv_nm_interface+set}" = set; then
4716 $as_echo_n "(cached) " >&6
4717 else
4718 lt_cv_nm_interface="BSD nm"
4719 echo "int some_variable = 0;" > conftest.$ac_ext
4720 (eval echo "\"\$as_me:4720: $ac_compile\"" >&5)
4721 (eval "$ac_compile" 2>conftest.err)
4722 cat conftest.err >&5
4723 (eval echo "\"\$as_me:4723: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
4724 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
4725 cat conftest.err >&5
4726 (eval echo "\"\$as_me:4726: output\"" >&5)
4727 cat conftest.out >&5
4728 if $GREP 'External.*some_variable' conftest.out > /dev/null; then
4729 lt_cv_nm_interface="MS dumpbin"
4731 rm -f conftest*
4733 { $as_echo "$as_me:$LINENO: result: $lt_cv_nm_interface" >&5
4734 $as_echo "$lt_cv_nm_interface" >&6; }
4736 { $as_echo "$as_me:$LINENO: checking whether ln -s works" >&5
4737 $as_echo_n "checking whether ln -s works... " >&6; }
4738 LN_S=$as_ln_s
4739 if test "$LN_S" = "ln -s"; then
4740 { $as_echo "$as_me:$LINENO: result: yes" >&5
4741 $as_echo "yes" >&6; }
4742 else
4743 { $as_echo "$as_me:$LINENO: result: no, using $LN_S" >&5
4744 $as_echo "no, using $LN_S" >&6; }
4747 # find the maximum length of command line arguments
4748 { $as_echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5
4749 $as_echo_n "checking the maximum length of command line arguments... " >&6; }
4750 if test "${lt_cv_sys_max_cmd_len+set}" = set; then
4751 $as_echo_n "(cached) " >&6
4752 else
4754 teststring="ABCD"
4756 case $build_os in
4757 msdosdjgpp*)
4758 # On DJGPP, this test can blow up pretty badly due to problems in libc
4759 # (any single argument exceeding 2000 bytes causes a buffer overrun
4760 # during glob expansion). Even if it were fixed, the result of this
4761 # check would be larger than it should be.
4762 lt_cv_sys_max_cmd_len=12288; # 12K is about right
4765 gnu*)
4766 # Under GNU Hurd, this test is not required because there is
4767 # no limit to the length of command line arguments.
4768 # Libtool will interpret -1 as no limit whatsoever
4769 lt_cv_sys_max_cmd_len=-1;
4772 cygwin* | mingw* | cegcc*)
4773 # On Win9x/ME, this test blows up -- it succeeds, but takes
4774 # about 5 minutes as the teststring grows exponentially.
4775 # Worse, since 9x/ME are not pre-emptively multitasking,
4776 # you end up with a "frozen" computer, even though with patience
4777 # the test eventually succeeds (with a max line length of 256k).
4778 # Instead, let's just punt: use the minimum linelength reported by
4779 # all of the supported platforms: 8192 (on NT/2K/XP).
4780 lt_cv_sys_max_cmd_len=8192;
4783 amigaos*)
4784 # On AmigaOS with pdksh, this test takes hours, literally.
4785 # So we just punt and use a minimum line length of 8192.
4786 lt_cv_sys_max_cmd_len=8192;
4789 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
4790 # This has been around since 386BSD, at least. Likely further.
4791 if test -x /sbin/sysctl; then
4792 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
4793 elif test -x /usr/sbin/sysctl; then
4794 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
4795 else
4796 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
4798 # And add a safety zone
4799 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
4800 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
4803 interix*)
4804 # We know the value 262144 and hardcode it with a safety zone (like BSD)
4805 lt_cv_sys_max_cmd_len=196608
4808 osf*)
4809 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
4810 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
4811 # nice to cause kernel panics so lets avoid the loop below.
4812 # First set a reasonable default.
4813 lt_cv_sys_max_cmd_len=16384
4815 if test -x /sbin/sysconfig; then
4816 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
4817 *1*) lt_cv_sys_max_cmd_len=-1 ;;
4818 esac
4821 sco3.2v5*)
4822 lt_cv_sys_max_cmd_len=102400
4824 sysv5* | sco5v6* | sysv4.2uw2*)
4825 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
4826 if test -n "$kargmax"; then
4827 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'`
4828 else
4829 lt_cv_sys_max_cmd_len=32768
4833 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
4834 if test -n "$lt_cv_sys_max_cmd_len"; then
4835 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
4836 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
4837 else
4838 # Make teststring a little bigger before we do anything with it.
4839 # a 1K string should be a reasonable start.
4840 for i in 1 2 3 4 5 6 7 8 ; do
4841 teststring=$teststring$teststring
4842 done
4843 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
4844 # If test is not a shell built-in, we'll probably end up computing a
4845 # maximum length that is only half of the actual maximum length, but
4846 # we can't tell.
4847 while { test "X"`$SHELL $0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \
4848 = "XX$teststring$teststring"; } >/dev/null 2>&1 &&
4849 test $i != 17 # 1/2 MB should be enough
4851 i=`expr $i + 1`
4852 teststring=$teststring$teststring
4853 done
4854 # Only check the string length outside the loop.
4855 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
4856 teststring=
4857 # Add a significant safety factor because C++ compilers can tack on
4858 # massive amounts of additional arguments before passing them to the
4859 # linker. It appears as though 1/2 is a usable value.
4860 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
4863 esac
4867 if test -n $lt_cv_sys_max_cmd_len ; then
4868 { $as_echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5
4869 $as_echo "$lt_cv_sys_max_cmd_len" >&6; }
4870 else
4871 { $as_echo "$as_me:$LINENO: result: none" >&5
4872 $as_echo "none" >&6; }
4874 max_cmd_len=$lt_cv_sys_max_cmd_len
4881 : ${CP="cp -f"}
4882 : ${MV="mv -f"}
4883 : ${RM="rm -f"}
4885 { $as_echo "$as_me:$LINENO: checking whether the shell understands some XSI constructs" >&5
4886 $as_echo_n "checking whether the shell understands some XSI constructs... " >&6; }
4887 # Try some XSI features
4888 xsi_shell=no
4889 ( _lt_dummy="a/b/c"
4890 test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
4891 = c,a/b,, \
4892 && eval 'test $(( 1 + 1 )) -eq 2 \
4893 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
4894 && xsi_shell=yes
4895 { $as_echo "$as_me:$LINENO: result: $xsi_shell" >&5
4896 $as_echo "$xsi_shell" >&6; }
4899 { $as_echo "$as_me:$LINENO: checking whether the shell understands \"+=\"" >&5
4900 $as_echo_n "checking whether the shell understands \"+=\"... " >&6; }
4901 lt_shell_append=no
4902 ( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
4903 >/dev/null 2>&1 \
4904 && lt_shell_append=yes
4905 { $as_echo "$as_me:$LINENO: result: $lt_shell_append" >&5
4906 $as_echo "$lt_shell_append" >&6; }
4909 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
4910 lt_unset=unset
4911 else
4912 lt_unset=false
4919 # test EBCDIC or ASCII
4920 case `echo X|tr X '\101'` in
4921 A) # ASCII based system
4922 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
4923 lt_SP2NL='tr \040 \012'
4924 lt_NL2SP='tr \015\012 \040\040'
4926 *) # EBCDIC based system
4927 lt_SP2NL='tr \100 \n'
4928 lt_NL2SP='tr \r\n \100\100'
4930 esac
4940 { $as_echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5
4941 $as_echo_n "checking for $LD option to reload object files... " >&6; }
4942 if test "${lt_cv_ld_reload_flag+set}" = set; then
4943 $as_echo_n "(cached) " >&6
4944 else
4945 lt_cv_ld_reload_flag='-r'
4947 { $as_echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5
4948 $as_echo "$lt_cv_ld_reload_flag" >&6; }
4949 reload_flag=$lt_cv_ld_reload_flag
4950 case $reload_flag in
4951 "" | " "*) ;;
4952 *) reload_flag=" $reload_flag" ;;
4953 esac
4954 reload_cmds='$LD$reload_flag -o $output$reload_objs'
4955 case $host_os in
4956 darwin*)
4957 if test "$GCC" = yes; then
4958 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
4959 else
4960 reload_cmds='$LD$reload_flag -o $output$reload_objs'
4963 esac
4973 if test -n "$ac_tool_prefix"; then
4974 # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
4975 set dummy ${ac_tool_prefix}objdump; ac_word=$2
4976 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
4977 $as_echo_n "checking for $ac_word... " >&6; }
4978 if test "${ac_cv_prog_OBJDUMP+set}" = set; then
4979 $as_echo_n "(cached) " >&6
4980 else
4981 if test -n "$OBJDUMP"; then
4982 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
4983 else
4984 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4985 for as_dir in $PATH
4987 IFS=$as_save_IFS
4988 test -z "$as_dir" && as_dir=.
4989 for ac_exec_ext in '' $ac_executable_extensions; do
4990 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4991 ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
4992 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4993 break 2
4995 done
4996 done
4997 IFS=$as_save_IFS
5001 OBJDUMP=$ac_cv_prog_OBJDUMP
5002 if test -n "$OBJDUMP"; then
5003 { $as_echo "$as_me:$LINENO: result: $OBJDUMP" >&5
5004 $as_echo "$OBJDUMP" >&6; }
5005 else
5006 { $as_echo "$as_me:$LINENO: result: no" >&5
5007 $as_echo "no" >&6; }
5012 if test -z "$ac_cv_prog_OBJDUMP"; then
5013 ac_ct_OBJDUMP=$OBJDUMP
5014 # Extract the first word of "objdump", so it can be a program name with args.
5015 set dummy objdump; ac_word=$2
5016 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5017 $as_echo_n "checking for $ac_word... " >&6; }
5018 if test "${ac_cv_prog_ac_ct_OBJDUMP+set}" = set; then
5019 $as_echo_n "(cached) " >&6
5020 else
5021 if test -n "$ac_ct_OBJDUMP"; then
5022 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
5023 else
5024 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5025 for as_dir in $PATH
5027 IFS=$as_save_IFS
5028 test -z "$as_dir" && as_dir=.
5029 for ac_exec_ext in '' $ac_executable_extensions; do
5030 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5031 ac_cv_prog_ac_ct_OBJDUMP="objdump"
5032 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5033 break 2
5035 done
5036 done
5037 IFS=$as_save_IFS
5041 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
5042 if test -n "$ac_ct_OBJDUMP"; then
5043 { $as_echo "$as_me:$LINENO: result: $ac_ct_OBJDUMP" >&5
5044 $as_echo "$ac_ct_OBJDUMP" >&6; }
5045 else
5046 { $as_echo "$as_me:$LINENO: result: no" >&5
5047 $as_echo "no" >&6; }
5050 if test "x$ac_ct_OBJDUMP" = x; then
5051 OBJDUMP="false"
5052 else
5053 case $cross_compiling:$ac_tool_warned in
5054 yes:)
5055 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
5056 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5057 ac_tool_warned=yes ;;
5058 esac
5059 OBJDUMP=$ac_ct_OBJDUMP
5061 else
5062 OBJDUMP="$ac_cv_prog_OBJDUMP"
5065 test -z "$OBJDUMP" && OBJDUMP=objdump
5075 { $as_echo "$as_me:$LINENO: checking how to recognize dependent libraries" >&5
5076 $as_echo_n "checking how to recognize dependent libraries... " >&6; }
5077 if test "${lt_cv_deplibs_check_method+set}" = set; then
5078 $as_echo_n "(cached) " >&6
5079 else
5080 lt_cv_file_magic_cmd='$MAGIC_CMD'
5081 lt_cv_file_magic_test_file=
5082 lt_cv_deplibs_check_method='unknown'
5083 # Need to set the preceding variable on all platforms that support
5084 # interlibrary dependencies.
5085 # 'none' -- dependencies not supported.
5086 # `unknown' -- same as none, but documents that we really don't know.
5087 # 'pass_all' -- all dependencies passed with no checks.
5088 # 'test_compile' -- check by making test program.
5089 # 'file_magic [[regex]]' -- check by looking for files in library path
5090 # which responds to the $file_magic_cmd with a given extended regex.
5091 # If you have `file' or equivalent on your system and you're not sure
5092 # whether `pass_all' will *always* work, you probably want this one.
5094 case $host_os in
5095 aix[4-9]*)
5096 lt_cv_deplibs_check_method=pass_all
5099 beos*)
5100 lt_cv_deplibs_check_method=pass_all
5103 bsdi[45]*)
5104 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
5105 lt_cv_file_magic_cmd='/usr/bin/file -L'
5106 lt_cv_file_magic_test_file=/shlib/libc.so
5109 cygwin*)
5110 # func_win32_libid is a shell function defined in ltmain.sh
5111 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
5112 lt_cv_file_magic_cmd='func_win32_libid'
5115 mingw* | pw32*)
5116 # Base MSYS/MinGW do not provide the 'file' command needed by
5117 # func_win32_libid shell function, so use a weaker test based on 'objdump',
5118 # unless we find 'file', for example because we are cross-compiling.
5119 if ( file / ) >/dev/null 2>&1; then
5120 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
5121 lt_cv_file_magic_cmd='func_win32_libid'
5122 else
5123 lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
5124 lt_cv_file_magic_cmd='$OBJDUMP -f'
5128 cegcc)
5129 # use the weaker test based on 'objdump'. See mingw*.
5130 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
5131 lt_cv_file_magic_cmd='$OBJDUMP -f'
5134 darwin* | rhapsody*)
5135 lt_cv_deplibs_check_method=pass_all
5138 freebsd* | dragonfly*)
5139 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
5140 case $host_cpu in
5141 i*86 )
5142 # Not sure whether the presence of OpenBSD here was a mistake.
5143 # Let's accept both of them until this is cleared up.
5144 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
5145 lt_cv_file_magic_cmd=/usr/bin/file
5146 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
5148 esac
5149 else
5150 lt_cv_deplibs_check_method=pass_all
5154 gnu*)
5155 lt_cv_deplibs_check_method=pass_all
5158 hpux10.20* | hpux11*)
5159 lt_cv_file_magic_cmd=/usr/bin/file
5160 case $host_cpu in
5161 ia64*)
5162 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
5163 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
5165 hppa*64*)
5166 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'
5167 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
5170 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
5171 lt_cv_file_magic_test_file=/usr/lib/libc.sl
5173 esac
5176 interix[3-9]*)
5177 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
5178 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
5181 irix5* | irix6* | nonstopux*)
5182 case $LD in
5183 *-32|*"-32 ") libmagic=32-bit;;
5184 *-n32|*"-n32 ") libmagic=N32;;
5185 *-64|*"-64 ") libmagic=64-bit;;
5186 *) libmagic=never-match;;
5187 esac
5188 lt_cv_deplibs_check_method=pass_all
5191 # This must be Linux ELF.
5192 linux* | k*bsd*-gnu)
5193 lt_cv_deplibs_check_method=pass_all
5196 netbsd*)
5197 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
5198 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
5199 else
5200 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
5204 newos6*)
5205 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
5206 lt_cv_file_magic_cmd=/usr/bin/file
5207 lt_cv_file_magic_test_file=/usr/lib/libnls.so
5210 *nto* | *qnx*)
5211 lt_cv_deplibs_check_method=pass_all
5214 openbsd*)
5215 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
5216 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
5217 else
5218 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
5222 osf3* | osf4* | osf5*)
5223 lt_cv_deplibs_check_method=pass_all
5226 rdos*)
5227 lt_cv_deplibs_check_method=pass_all
5230 solaris*)
5231 lt_cv_deplibs_check_method=pass_all
5234 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
5235 lt_cv_deplibs_check_method=pass_all
5238 sysv4 | sysv4.3*)
5239 case $host_vendor in
5240 motorola)
5241 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]'
5242 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
5244 ncr)
5245 lt_cv_deplibs_check_method=pass_all
5247 sequent)
5248 lt_cv_file_magic_cmd='/bin/file'
5249 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
5251 sni)
5252 lt_cv_file_magic_cmd='/bin/file'
5253 lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
5254 lt_cv_file_magic_test_file=/lib/libc.so
5256 siemens)
5257 lt_cv_deplibs_check_method=pass_all
5260 lt_cv_deplibs_check_method=pass_all
5262 esac
5265 tpf*)
5266 lt_cv_deplibs_check_method=pass_all
5268 esac
5271 { $as_echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5
5272 $as_echo "$lt_cv_deplibs_check_method" >&6; }
5273 file_magic_cmd=$lt_cv_file_magic_cmd
5274 deplibs_check_method=$lt_cv_deplibs_check_method
5275 test -z "$deplibs_check_method" && deplibs_check_method=unknown
5288 if test -n "$ac_tool_prefix"; then
5289 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
5290 set dummy ${ac_tool_prefix}ar; ac_word=$2
5291 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5292 $as_echo_n "checking for $ac_word... " >&6; }
5293 if test "${ac_cv_prog_AR+set}" = set; then
5294 $as_echo_n "(cached) " >&6
5295 else
5296 if test -n "$AR"; then
5297 ac_cv_prog_AR="$AR" # Let the user override the test.
5298 else
5299 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5300 for as_dir in $PATH
5302 IFS=$as_save_IFS
5303 test -z "$as_dir" && as_dir=.
5304 for ac_exec_ext in '' $ac_executable_extensions; do
5305 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5306 ac_cv_prog_AR="${ac_tool_prefix}ar"
5307 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5308 break 2
5310 done
5311 done
5312 IFS=$as_save_IFS
5316 AR=$ac_cv_prog_AR
5317 if test -n "$AR"; then
5318 { $as_echo "$as_me:$LINENO: result: $AR" >&5
5319 $as_echo "$AR" >&6; }
5320 else
5321 { $as_echo "$as_me:$LINENO: result: no" >&5
5322 $as_echo "no" >&6; }
5327 if test -z "$ac_cv_prog_AR"; then
5328 ac_ct_AR=$AR
5329 # Extract the first word of "ar", so it can be a program name with args.
5330 set dummy ar; ac_word=$2
5331 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5332 $as_echo_n "checking for $ac_word... " >&6; }
5333 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
5334 $as_echo_n "(cached) " >&6
5335 else
5336 if test -n "$ac_ct_AR"; then
5337 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
5338 else
5339 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5340 for as_dir in $PATH
5342 IFS=$as_save_IFS
5343 test -z "$as_dir" && as_dir=.
5344 for ac_exec_ext in '' $ac_executable_extensions; do
5345 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5346 ac_cv_prog_ac_ct_AR="ar"
5347 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5348 break 2
5350 done
5351 done
5352 IFS=$as_save_IFS
5356 ac_ct_AR=$ac_cv_prog_ac_ct_AR
5357 if test -n "$ac_ct_AR"; then
5358 { $as_echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
5359 $as_echo "$ac_ct_AR" >&6; }
5360 else
5361 { $as_echo "$as_me:$LINENO: result: no" >&5
5362 $as_echo "no" >&6; }
5365 if test "x$ac_ct_AR" = x; then
5366 AR="false"
5367 else
5368 case $cross_compiling:$ac_tool_warned in
5369 yes:)
5370 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
5371 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5372 ac_tool_warned=yes ;;
5373 esac
5374 AR=$ac_ct_AR
5376 else
5377 AR="$ac_cv_prog_AR"
5380 test -z "$AR" && AR=ar
5381 test -z "$AR_FLAGS" && AR_FLAGS=cru
5393 if test -n "$ac_tool_prefix"; then
5394 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
5395 set dummy ${ac_tool_prefix}strip; ac_word=$2
5396 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5397 $as_echo_n "checking for $ac_word... " >&6; }
5398 if test "${ac_cv_prog_STRIP+set}" = set; then
5399 $as_echo_n "(cached) " >&6
5400 else
5401 if test -n "$STRIP"; then
5402 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
5403 else
5404 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5405 for as_dir in $PATH
5407 IFS=$as_save_IFS
5408 test -z "$as_dir" && as_dir=.
5409 for ac_exec_ext in '' $ac_executable_extensions; do
5410 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5411 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
5412 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5413 break 2
5415 done
5416 done
5417 IFS=$as_save_IFS
5421 STRIP=$ac_cv_prog_STRIP
5422 if test -n "$STRIP"; then
5423 { $as_echo "$as_me:$LINENO: result: $STRIP" >&5
5424 $as_echo "$STRIP" >&6; }
5425 else
5426 { $as_echo "$as_me:$LINENO: result: no" >&5
5427 $as_echo "no" >&6; }
5432 if test -z "$ac_cv_prog_STRIP"; then
5433 ac_ct_STRIP=$STRIP
5434 # Extract the first word of "strip", so it can be a program name with args.
5435 set dummy strip; ac_word=$2
5436 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5437 $as_echo_n "checking for $ac_word... " >&6; }
5438 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
5439 $as_echo_n "(cached) " >&6
5440 else
5441 if test -n "$ac_ct_STRIP"; then
5442 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
5443 else
5444 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5445 for as_dir in $PATH
5447 IFS=$as_save_IFS
5448 test -z "$as_dir" && as_dir=.
5449 for ac_exec_ext in '' $ac_executable_extensions; do
5450 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5451 ac_cv_prog_ac_ct_STRIP="strip"
5452 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5453 break 2
5455 done
5456 done
5457 IFS=$as_save_IFS
5461 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
5462 if test -n "$ac_ct_STRIP"; then
5463 { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
5464 $as_echo "$ac_ct_STRIP" >&6; }
5465 else
5466 { $as_echo "$as_me:$LINENO: result: no" >&5
5467 $as_echo "no" >&6; }
5470 if test "x$ac_ct_STRIP" = x; then
5471 STRIP=":"
5472 else
5473 case $cross_compiling:$ac_tool_warned in
5474 yes:)
5475 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
5476 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5477 ac_tool_warned=yes ;;
5478 esac
5479 STRIP=$ac_ct_STRIP
5481 else
5482 STRIP="$ac_cv_prog_STRIP"
5485 test -z "$STRIP" && STRIP=:
5492 if test -n "$ac_tool_prefix"; then
5493 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5494 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5495 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5496 $as_echo_n "checking for $ac_word... " >&6; }
5497 if test "${ac_cv_prog_RANLIB+set}" = set; then
5498 $as_echo_n "(cached) " >&6
5499 else
5500 if test -n "$RANLIB"; then
5501 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5502 else
5503 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5504 for as_dir in $PATH
5506 IFS=$as_save_IFS
5507 test -z "$as_dir" && as_dir=.
5508 for ac_exec_ext in '' $ac_executable_extensions; do
5509 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5510 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5511 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5512 break 2
5514 done
5515 done
5516 IFS=$as_save_IFS
5520 RANLIB=$ac_cv_prog_RANLIB
5521 if test -n "$RANLIB"; then
5522 { $as_echo "$as_me:$LINENO: result: $RANLIB" >&5
5523 $as_echo "$RANLIB" >&6; }
5524 else
5525 { $as_echo "$as_me:$LINENO: result: no" >&5
5526 $as_echo "no" >&6; }
5531 if test -z "$ac_cv_prog_RANLIB"; then
5532 ac_ct_RANLIB=$RANLIB
5533 # Extract the first word of "ranlib", so it can be a program name with args.
5534 set dummy ranlib; ac_word=$2
5535 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5536 $as_echo_n "checking for $ac_word... " >&6; }
5537 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
5538 $as_echo_n "(cached) " >&6
5539 else
5540 if test -n "$ac_ct_RANLIB"; then
5541 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5542 else
5543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5544 for as_dir in $PATH
5546 IFS=$as_save_IFS
5547 test -z "$as_dir" && as_dir=.
5548 for ac_exec_ext in '' $ac_executable_extensions; do
5549 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5550 ac_cv_prog_ac_ct_RANLIB="ranlib"
5551 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5552 break 2
5554 done
5555 done
5556 IFS=$as_save_IFS
5560 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5561 if test -n "$ac_ct_RANLIB"; then
5562 { $as_echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
5563 $as_echo "$ac_ct_RANLIB" >&6; }
5564 else
5565 { $as_echo "$as_me:$LINENO: result: no" >&5
5566 $as_echo "no" >&6; }
5569 if test "x$ac_ct_RANLIB" = x; then
5570 RANLIB=":"
5571 else
5572 case $cross_compiling:$ac_tool_warned in
5573 yes:)
5574 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
5575 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5576 ac_tool_warned=yes ;;
5577 esac
5578 RANLIB=$ac_ct_RANLIB
5580 else
5581 RANLIB="$ac_cv_prog_RANLIB"
5584 test -z "$RANLIB" && RANLIB=:
5591 # Determine commands to create old-style static archives.
5592 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
5593 old_postinstall_cmds='chmod 644 $oldlib'
5594 old_postuninstall_cmds=
5596 if test -n "$RANLIB"; then
5597 case $host_os in
5598 openbsd*)
5599 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
5602 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
5604 esac
5605 old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
5641 # If no C compiler was specified, use CC.
5642 LTCC=${LTCC-"$CC"}
5644 # If no C compiler flags were specified, use CFLAGS.
5645 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
5647 # Allow CC to be a program name with arguments.
5648 compiler=$CC
5651 # Check for command to grab the raw symbol name followed by C symbol from nm.
5652 { $as_echo "$as_me:$LINENO: checking command to parse $NM output from $compiler object" >&5
5653 $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
5654 if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then
5655 $as_echo_n "(cached) " >&6
5656 else
5658 # These are sane defaults that work on at least a few old systems.
5659 # [They come from Ultrix. What could be older than Ultrix?!! ;)]
5661 # Character class describing NM global symbol codes.
5662 symcode='[BCDEGRST]'
5664 # Regexp to match symbols that can be accessed directly from C.
5665 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
5667 # Define system-specific variables.
5668 case $host_os in
5669 aix*)
5670 symcode='[BCDT]'
5672 cygwin* | mingw* | pw32* | cegcc*)
5673 symcode='[ABCDGISTW]'
5675 hpux*)
5676 if test "$host_cpu" = ia64; then
5677 symcode='[ABCDEGRST]'
5680 irix* | nonstopux*)
5681 symcode='[BCDEGRST]'
5683 osf*)
5684 symcode='[BCDEGQRST]'
5686 solaris*)
5687 symcode='[BDRT]'
5689 sco3.2v5*)
5690 symcode='[DT]'
5692 sysv4.2uw2*)
5693 symcode='[DT]'
5695 sysv5* | sco5v6* | unixware* | OpenUNIX*)
5696 symcode='[ABDT]'
5698 sysv4)
5699 symcode='[DFNSTU]'
5701 esac
5703 # If we're using GNU nm, then use its standard symbol codes.
5704 case `$NM -V 2>&1` in
5705 *GNU* | *'with BFD'*)
5706 symcode='[ABCDGIRSTW]' ;;
5707 esac
5709 # Transform an extracted symbol line into a proper C declaration.
5710 # Some systems (esp. on ia64) link data and code symbols differently,
5711 # so use this general approach.
5712 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
5714 # Transform an extracted symbol line into symbol name and symbol address
5715 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
5716 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'"
5718 # Handle CRLF in mingw tool chain
5719 opt_cr=
5720 case $build_os in
5721 mingw*)
5722 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
5724 esac
5726 # Try without a prefix underscore, then with it.
5727 for ac_symprfx in "" "_"; do
5729 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
5730 symxfrm="\\1 $ac_symprfx\\2 \\2"
5732 # Write the raw and C identifiers.
5733 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
5734 # Fake it for dumpbin and say T for any non-static function
5735 # and D for any global variable.
5736 # Also find C++ and __fastcall symbols from MSVC++,
5737 # which start with @ or ?.
5738 lt_cv_sys_global_symbol_pipe="$AWK '"\
5739 " {last_section=section; section=\$ 3};"\
5740 " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
5741 " \$ 0!~/External *\|/{next};"\
5742 " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
5743 " {if(hide[section]) next};"\
5744 " {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
5745 " {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
5746 " s[1]~/^[@?]/{print s[1], s[1]; next};"\
5747 " s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
5748 " ' prfx=^$ac_symprfx"
5749 else
5750 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
5753 # Check to see that the pipe works correctly.
5754 pipe_works=no
5756 rm -f conftest*
5757 cat > conftest.$ac_ext <<_LT_EOF
5758 #ifdef __cplusplus
5759 extern "C" {
5760 #endif
5761 char nm_test_var;
5762 void nm_test_func(void);
5763 void nm_test_func(void){}
5764 #ifdef __cplusplus
5766 #endif
5767 int main(){nm_test_var='a';nm_test_func();return(0);}
5768 _LT_EOF
5770 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5771 (eval $ac_compile) 2>&5
5772 ac_status=$?
5773 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5774 (exit $ac_status); }; then
5775 # Now try to grab the symbols.
5776 nlist=conftest.nm
5777 if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\"") >&5
5778 (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5
5779 ac_status=$?
5780 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5781 (exit $ac_status); } && test -s "$nlist"; then
5782 # Try sorting and uniquifying the output.
5783 if sort "$nlist" | uniq > "$nlist"T; then
5784 mv -f "$nlist"T "$nlist"
5785 else
5786 rm -f "$nlist"T
5789 # Make sure that we snagged all the symbols we need.
5790 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
5791 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
5792 cat <<_LT_EOF > conftest.$ac_ext
5793 #ifdef __cplusplus
5794 extern "C" {
5795 #endif
5797 _LT_EOF
5798 # Now generate the symbol file.
5799 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
5801 cat <<_LT_EOF >> conftest.$ac_ext
5803 /* The mapping between symbol names and symbols. */
5804 const struct {
5805 const char *name;
5806 void *address;
5808 lt__PROGRAM__LTX_preloaded_symbols[] =
5810 { "@PROGRAM@", (void *) 0 },
5811 _LT_EOF
5812 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
5813 cat <<\_LT_EOF >> conftest.$ac_ext
5814 {0, (void *) 0}
5817 /* This works around a problem in FreeBSD linker */
5818 #ifdef FREEBSD_WORKAROUND
5819 static const void *lt_preloaded_setup() {
5820 return lt__PROGRAM__LTX_preloaded_symbols;
5822 #endif
5824 #ifdef __cplusplus
5826 #endif
5827 _LT_EOF
5828 # Now try linking the two files.
5829 mv conftest.$ac_objext conftstm.$ac_objext
5830 lt_save_LIBS="$LIBS"
5831 lt_save_CFLAGS="$CFLAGS"
5832 LIBS="conftstm.$ac_objext"
5833 CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
5834 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5835 (eval $ac_link) 2>&5
5836 ac_status=$?
5837 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5838 (exit $ac_status); } && test -s conftest${ac_exeext}; then
5839 pipe_works=yes
5841 LIBS="$lt_save_LIBS"
5842 CFLAGS="$lt_save_CFLAGS"
5843 else
5844 echo "cannot find nm_test_func in $nlist" >&5
5846 else
5847 echo "cannot find nm_test_var in $nlist" >&5
5849 else
5850 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
5852 else
5853 echo "$progname: failed program was:" >&5
5854 cat conftest.$ac_ext >&5
5856 rm -rf conftest* conftst*
5858 # Do not use the global_symbol_pipe unless it works.
5859 if test "$pipe_works" = yes; then
5860 break
5861 else
5862 lt_cv_sys_global_symbol_pipe=
5864 done
5868 if test -z "$lt_cv_sys_global_symbol_pipe"; then
5869 lt_cv_sys_global_symbol_to_cdecl=
5871 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
5872 { $as_echo "$as_me:$LINENO: result: failed" >&5
5873 $as_echo "failed" >&6; }
5874 else
5875 { $as_echo "$as_me:$LINENO: result: ok" >&5
5876 $as_echo "ok" >&6; }
5901 # Check whether --enable-libtool-lock was given.
5902 if test "${enable_libtool_lock+set}" = set; then
5903 enableval=$enable_libtool_lock;
5906 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
5908 # Some flags need to be propagated to the compiler or linker for good
5909 # libtool support.
5910 case $host in
5911 ia64-*-hpux*)
5912 # Find out which ABI we are using.
5913 echo 'int i;' > conftest.$ac_ext
5914 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5915 (eval $ac_compile) 2>&5
5916 ac_status=$?
5917 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5918 (exit $ac_status); }; then
5919 case `/usr/bin/file conftest.$ac_objext` in
5920 *ELF-32*)
5921 HPUX_IA64_MODE="32"
5923 *ELF-64*)
5924 HPUX_IA64_MODE="64"
5926 esac
5928 rm -rf conftest*
5930 *-*-irix6*)
5931 # Find out which ABI we are using.
5932 echo '#line 5932 "configure"' > conftest.$ac_ext
5933 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5934 (eval $ac_compile) 2>&5
5935 ac_status=$?
5936 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5937 (exit $ac_status); }; then
5938 if test "$lt_cv_prog_gnu_ld" = yes; then
5939 case `/usr/bin/file conftest.$ac_objext` in
5940 *32-bit*)
5941 LD="${LD-ld} -melf32bsmip"
5943 *N32*)
5944 LD="${LD-ld} -melf32bmipn32"
5946 *64-bit*)
5947 LD="${LD-ld} -melf64bmip"
5949 esac
5950 else
5951 case `/usr/bin/file conftest.$ac_objext` in
5952 *32-bit*)
5953 LD="${LD-ld} -32"
5955 *N32*)
5956 LD="${LD-ld} -n32"
5958 *64-bit*)
5959 LD="${LD-ld} -64"
5961 esac
5964 rm -rf conftest*
5967 x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
5968 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
5969 # Find out which ABI we are using.
5970 echo 'int i;' > conftest.$ac_ext
5971 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5972 (eval $ac_compile) 2>&5
5973 ac_status=$?
5974 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5975 (exit $ac_status); }; then
5976 case `/usr/bin/file conftest.o` in
5977 *32-bit*)
5978 case $host in
5979 x86_64-*kfreebsd*-gnu)
5980 LD="${LD-ld} -m elf_i386_fbsd"
5982 x86_64-*linux*)
5983 LD="${LD-ld} -m elf_i386"
5985 ppc64-*linux*|powerpc64-*linux*)
5986 LD="${LD-ld} -m elf32ppclinux"
5988 s390x-*linux*)
5989 LD="${LD-ld} -m elf_s390"
5991 sparc64-*linux*)
5992 LD="${LD-ld} -m elf32_sparc"
5994 esac
5996 *64-bit*)
5997 case $host in
5998 x86_64-*kfreebsd*-gnu)
5999 LD="${LD-ld} -m elf_x86_64_fbsd"
6001 x86_64-*linux*)
6002 LD="${LD-ld} -m elf_x86_64"
6004 ppc*-*linux*|powerpc*-*linux*)
6005 LD="${LD-ld} -m elf64ppc"
6007 s390*-*linux*|s390*-*tpf*)
6008 LD="${LD-ld} -m elf64_s390"
6010 sparc*-*linux*)
6011 LD="${LD-ld} -m elf64_sparc"
6013 esac
6015 esac
6017 rm -rf conftest*
6020 *-*-sco3.2v5*)
6021 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
6022 SAVE_CFLAGS="$CFLAGS"
6023 CFLAGS="$CFLAGS -belf"
6024 { $as_echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5
6025 $as_echo_n "checking whether the C compiler needs -belf... " >&6; }
6026 if test "${lt_cv_cc_needs_belf+set}" = set; then
6027 $as_echo_n "(cached) " >&6
6028 else
6029 ac_ext=c
6030 ac_cpp='$CPP $CPPFLAGS'
6031 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6032 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6033 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6035 cat >conftest.$ac_ext <<_ACEOF
6036 /* confdefs.h. */
6037 _ACEOF
6038 cat confdefs.h >>conftest.$ac_ext
6039 cat >>conftest.$ac_ext <<_ACEOF
6040 /* end confdefs.h. */
6043 main ()
6047 return 0;
6049 _ACEOF
6050 rm -f conftest.$ac_objext conftest$ac_exeext
6051 if { (ac_try="$ac_link"
6052 case "(($ac_try" in
6053 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6054 *) ac_try_echo=$ac_try;;
6055 esac
6056 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6057 $as_echo "$ac_try_echo") >&5
6058 (eval "$ac_link") 2>conftest.er1
6059 ac_status=$?
6060 grep -v '^ *+' conftest.er1 >conftest.err
6061 rm -f conftest.er1
6062 cat conftest.err >&5
6063 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6064 (exit $ac_status); } && {
6065 test -z "$ac_c_werror_flag" ||
6066 test ! -s conftest.err
6067 } && test -s conftest$ac_exeext && {
6068 test "$cross_compiling" = yes ||
6069 $as_test_x conftest$ac_exeext
6070 }; then
6071 lt_cv_cc_needs_belf=yes
6072 else
6073 $as_echo "$as_me: failed program was:" >&5
6074 sed 's/^/| /' conftest.$ac_ext >&5
6076 lt_cv_cc_needs_belf=no
6079 rm -rf conftest.dSYM
6080 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6081 conftest$ac_exeext conftest.$ac_ext
6082 ac_ext=c
6083 ac_cpp='$CPP $CPPFLAGS'
6084 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6085 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6086 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6089 { $as_echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5
6090 $as_echo "$lt_cv_cc_needs_belf" >&6; }
6091 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
6092 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
6093 CFLAGS="$SAVE_CFLAGS"
6096 sparc*-*solaris*)
6097 # Find out which ABI we are using.
6098 echo 'int i;' > conftest.$ac_ext
6099 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6100 (eval $ac_compile) 2>&5
6101 ac_status=$?
6102 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6103 (exit $ac_status); }; then
6104 case `/usr/bin/file conftest.o` in
6105 *64-bit*)
6106 case $lt_cv_prog_gnu_ld in
6107 yes*) LD="${LD-ld} -m elf64_sparc" ;;
6109 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
6110 LD="${LD-ld} -64"
6113 esac
6115 esac
6117 rm -rf conftest*
6119 esac
6121 need_locks="$enable_libtool_lock"
6124 case $host_os in
6125 rhapsody* | darwin*)
6126 if test -n "$ac_tool_prefix"; then
6127 # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
6128 set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
6129 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6130 $as_echo_n "checking for $ac_word... " >&6; }
6131 if test "${ac_cv_prog_DSYMUTIL+set}" = set; then
6132 $as_echo_n "(cached) " >&6
6133 else
6134 if test -n "$DSYMUTIL"; then
6135 ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
6136 else
6137 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6138 for as_dir in $PATH
6140 IFS=$as_save_IFS
6141 test -z "$as_dir" && as_dir=.
6142 for ac_exec_ext in '' $ac_executable_extensions; do
6143 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6144 ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
6145 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6146 break 2
6148 done
6149 done
6150 IFS=$as_save_IFS
6154 DSYMUTIL=$ac_cv_prog_DSYMUTIL
6155 if test -n "$DSYMUTIL"; then
6156 { $as_echo "$as_me:$LINENO: result: $DSYMUTIL" >&5
6157 $as_echo "$DSYMUTIL" >&6; }
6158 else
6159 { $as_echo "$as_me:$LINENO: result: no" >&5
6160 $as_echo "no" >&6; }
6165 if test -z "$ac_cv_prog_DSYMUTIL"; then
6166 ac_ct_DSYMUTIL=$DSYMUTIL
6167 # Extract the first word of "dsymutil", so it can be a program name with args.
6168 set dummy dsymutil; ac_word=$2
6169 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6170 $as_echo_n "checking for $ac_word... " >&6; }
6171 if test "${ac_cv_prog_ac_ct_DSYMUTIL+set}" = set; then
6172 $as_echo_n "(cached) " >&6
6173 else
6174 if test -n "$ac_ct_DSYMUTIL"; then
6175 ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
6176 else
6177 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6178 for as_dir in $PATH
6180 IFS=$as_save_IFS
6181 test -z "$as_dir" && as_dir=.
6182 for ac_exec_ext in '' $ac_executable_extensions; do
6183 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6184 ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
6185 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6186 break 2
6188 done
6189 done
6190 IFS=$as_save_IFS
6194 ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
6195 if test -n "$ac_ct_DSYMUTIL"; then
6196 { $as_echo "$as_me:$LINENO: result: $ac_ct_DSYMUTIL" >&5
6197 $as_echo "$ac_ct_DSYMUTIL" >&6; }
6198 else
6199 { $as_echo "$as_me:$LINENO: result: no" >&5
6200 $as_echo "no" >&6; }
6203 if test "x$ac_ct_DSYMUTIL" = x; then
6204 DSYMUTIL=":"
6205 else
6206 case $cross_compiling:$ac_tool_warned in
6207 yes:)
6208 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6209 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6210 ac_tool_warned=yes ;;
6211 esac
6212 DSYMUTIL=$ac_ct_DSYMUTIL
6214 else
6215 DSYMUTIL="$ac_cv_prog_DSYMUTIL"
6218 if test -n "$ac_tool_prefix"; then
6219 # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
6220 set dummy ${ac_tool_prefix}nmedit; ac_word=$2
6221 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6222 $as_echo_n "checking for $ac_word... " >&6; }
6223 if test "${ac_cv_prog_NMEDIT+set}" = set; then
6224 $as_echo_n "(cached) " >&6
6225 else
6226 if test -n "$NMEDIT"; then
6227 ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
6228 else
6229 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6230 for as_dir in $PATH
6232 IFS=$as_save_IFS
6233 test -z "$as_dir" && as_dir=.
6234 for ac_exec_ext in '' $ac_executable_extensions; do
6235 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6236 ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
6237 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6238 break 2
6240 done
6241 done
6242 IFS=$as_save_IFS
6246 NMEDIT=$ac_cv_prog_NMEDIT
6247 if test -n "$NMEDIT"; then
6248 { $as_echo "$as_me:$LINENO: result: $NMEDIT" >&5
6249 $as_echo "$NMEDIT" >&6; }
6250 else
6251 { $as_echo "$as_me:$LINENO: result: no" >&5
6252 $as_echo "no" >&6; }
6257 if test -z "$ac_cv_prog_NMEDIT"; then
6258 ac_ct_NMEDIT=$NMEDIT
6259 # Extract the first word of "nmedit", so it can be a program name with args.
6260 set dummy nmedit; ac_word=$2
6261 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6262 $as_echo_n "checking for $ac_word... " >&6; }
6263 if test "${ac_cv_prog_ac_ct_NMEDIT+set}" = set; then
6264 $as_echo_n "(cached) " >&6
6265 else
6266 if test -n "$ac_ct_NMEDIT"; then
6267 ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
6268 else
6269 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6270 for as_dir in $PATH
6272 IFS=$as_save_IFS
6273 test -z "$as_dir" && as_dir=.
6274 for ac_exec_ext in '' $ac_executable_extensions; do
6275 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6276 ac_cv_prog_ac_ct_NMEDIT="nmedit"
6277 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6278 break 2
6280 done
6281 done
6282 IFS=$as_save_IFS
6286 ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
6287 if test -n "$ac_ct_NMEDIT"; then
6288 { $as_echo "$as_me:$LINENO: result: $ac_ct_NMEDIT" >&5
6289 $as_echo "$ac_ct_NMEDIT" >&6; }
6290 else
6291 { $as_echo "$as_me:$LINENO: result: no" >&5
6292 $as_echo "no" >&6; }
6295 if test "x$ac_ct_NMEDIT" = x; then
6296 NMEDIT=":"
6297 else
6298 case $cross_compiling:$ac_tool_warned in
6299 yes:)
6300 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6301 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6302 ac_tool_warned=yes ;;
6303 esac
6304 NMEDIT=$ac_ct_NMEDIT
6306 else
6307 NMEDIT="$ac_cv_prog_NMEDIT"
6310 if test -n "$ac_tool_prefix"; then
6311 # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
6312 set dummy ${ac_tool_prefix}lipo; ac_word=$2
6313 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6314 $as_echo_n "checking for $ac_word... " >&6; }
6315 if test "${ac_cv_prog_LIPO+set}" = set; then
6316 $as_echo_n "(cached) " >&6
6317 else
6318 if test -n "$LIPO"; then
6319 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
6320 else
6321 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6322 for as_dir in $PATH
6324 IFS=$as_save_IFS
6325 test -z "$as_dir" && as_dir=.
6326 for ac_exec_ext in '' $ac_executable_extensions; do
6327 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6328 ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
6329 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6330 break 2
6332 done
6333 done
6334 IFS=$as_save_IFS
6338 LIPO=$ac_cv_prog_LIPO
6339 if test -n "$LIPO"; then
6340 { $as_echo "$as_me:$LINENO: result: $LIPO" >&5
6341 $as_echo "$LIPO" >&6; }
6342 else
6343 { $as_echo "$as_me:$LINENO: result: no" >&5
6344 $as_echo "no" >&6; }
6349 if test -z "$ac_cv_prog_LIPO"; then
6350 ac_ct_LIPO=$LIPO
6351 # Extract the first word of "lipo", so it can be a program name with args.
6352 set dummy lipo; ac_word=$2
6353 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6354 $as_echo_n "checking for $ac_word... " >&6; }
6355 if test "${ac_cv_prog_ac_ct_LIPO+set}" = set; then
6356 $as_echo_n "(cached) " >&6
6357 else
6358 if test -n "$ac_ct_LIPO"; then
6359 ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
6360 else
6361 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6362 for as_dir in $PATH
6364 IFS=$as_save_IFS
6365 test -z "$as_dir" && as_dir=.
6366 for ac_exec_ext in '' $ac_executable_extensions; do
6367 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6368 ac_cv_prog_ac_ct_LIPO="lipo"
6369 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6370 break 2
6372 done
6373 done
6374 IFS=$as_save_IFS
6378 ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
6379 if test -n "$ac_ct_LIPO"; then
6380 { $as_echo "$as_me:$LINENO: result: $ac_ct_LIPO" >&5
6381 $as_echo "$ac_ct_LIPO" >&6; }
6382 else
6383 { $as_echo "$as_me:$LINENO: result: no" >&5
6384 $as_echo "no" >&6; }
6387 if test "x$ac_ct_LIPO" = x; then
6388 LIPO=":"
6389 else
6390 case $cross_compiling:$ac_tool_warned in
6391 yes:)
6392 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6393 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6394 ac_tool_warned=yes ;;
6395 esac
6396 LIPO=$ac_ct_LIPO
6398 else
6399 LIPO="$ac_cv_prog_LIPO"
6402 if test -n "$ac_tool_prefix"; then
6403 # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
6404 set dummy ${ac_tool_prefix}otool; ac_word=$2
6405 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6406 $as_echo_n "checking for $ac_word... " >&6; }
6407 if test "${ac_cv_prog_OTOOL+set}" = set; then
6408 $as_echo_n "(cached) " >&6
6409 else
6410 if test -n "$OTOOL"; then
6411 ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
6412 else
6413 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6414 for as_dir in $PATH
6416 IFS=$as_save_IFS
6417 test -z "$as_dir" && as_dir=.
6418 for ac_exec_ext in '' $ac_executable_extensions; do
6419 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6420 ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
6421 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6422 break 2
6424 done
6425 done
6426 IFS=$as_save_IFS
6430 OTOOL=$ac_cv_prog_OTOOL
6431 if test -n "$OTOOL"; then
6432 { $as_echo "$as_me:$LINENO: result: $OTOOL" >&5
6433 $as_echo "$OTOOL" >&6; }
6434 else
6435 { $as_echo "$as_me:$LINENO: result: no" >&5
6436 $as_echo "no" >&6; }
6441 if test -z "$ac_cv_prog_OTOOL"; then
6442 ac_ct_OTOOL=$OTOOL
6443 # Extract the first word of "otool", so it can be a program name with args.
6444 set dummy otool; ac_word=$2
6445 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6446 $as_echo_n "checking for $ac_word... " >&6; }
6447 if test "${ac_cv_prog_ac_ct_OTOOL+set}" = set; then
6448 $as_echo_n "(cached) " >&6
6449 else
6450 if test -n "$ac_ct_OTOOL"; then
6451 ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
6452 else
6453 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6454 for as_dir in $PATH
6456 IFS=$as_save_IFS
6457 test -z "$as_dir" && as_dir=.
6458 for ac_exec_ext in '' $ac_executable_extensions; do
6459 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6460 ac_cv_prog_ac_ct_OTOOL="otool"
6461 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6462 break 2
6464 done
6465 done
6466 IFS=$as_save_IFS
6470 ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
6471 if test -n "$ac_ct_OTOOL"; then
6472 { $as_echo "$as_me:$LINENO: result: $ac_ct_OTOOL" >&5
6473 $as_echo "$ac_ct_OTOOL" >&6; }
6474 else
6475 { $as_echo "$as_me:$LINENO: result: no" >&5
6476 $as_echo "no" >&6; }
6479 if test "x$ac_ct_OTOOL" = x; then
6480 OTOOL=":"
6481 else
6482 case $cross_compiling:$ac_tool_warned in
6483 yes:)
6484 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6485 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6486 ac_tool_warned=yes ;;
6487 esac
6488 OTOOL=$ac_ct_OTOOL
6490 else
6491 OTOOL="$ac_cv_prog_OTOOL"
6494 if test -n "$ac_tool_prefix"; then
6495 # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
6496 set dummy ${ac_tool_prefix}otool64; ac_word=$2
6497 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6498 $as_echo_n "checking for $ac_word... " >&6; }
6499 if test "${ac_cv_prog_OTOOL64+set}" = set; then
6500 $as_echo_n "(cached) " >&6
6501 else
6502 if test -n "$OTOOL64"; then
6503 ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
6504 else
6505 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6506 for as_dir in $PATH
6508 IFS=$as_save_IFS
6509 test -z "$as_dir" && as_dir=.
6510 for ac_exec_ext in '' $ac_executable_extensions; do
6511 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6512 ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
6513 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6514 break 2
6516 done
6517 done
6518 IFS=$as_save_IFS
6522 OTOOL64=$ac_cv_prog_OTOOL64
6523 if test -n "$OTOOL64"; then
6524 { $as_echo "$as_me:$LINENO: result: $OTOOL64" >&5
6525 $as_echo "$OTOOL64" >&6; }
6526 else
6527 { $as_echo "$as_me:$LINENO: result: no" >&5
6528 $as_echo "no" >&6; }
6533 if test -z "$ac_cv_prog_OTOOL64"; then
6534 ac_ct_OTOOL64=$OTOOL64
6535 # Extract the first word of "otool64", so it can be a program name with args.
6536 set dummy otool64; ac_word=$2
6537 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6538 $as_echo_n "checking for $ac_word... " >&6; }
6539 if test "${ac_cv_prog_ac_ct_OTOOL64+set}" = set; then
6540 $as_echo_n "(cached) " >&6
6541 else
6542 if test -n "$ac_ct_OTOOL64"; then
6543 ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
6544 else
6545 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6546 for as_dir in $PATH
6548 IFS=$as_save_IFS
6549 test -z "$as_dir" && as_dir=.
6550 for ac_exec_ext in '' $ac_executable_extensions; do
6551 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6552 ac_cv_prog_ac_ct_OTOOL64="otool64"
6553 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6554 break 2
6556 done
6557 done
6558 IFS=$as_save_IFS
6562 ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
6563 if test -n "$ac_ct_OTOOL64"; then
6564 { $as_echo "$as_me:$LINENO: result: $ac_ct_OTOOL64" >&5
6565 $as_echo "$ac_ct_OTOOL64" >&6; }
6566 else
6567 { $as_echo "$as_me:$LINENO: result: no" >&5
6568 $as_echo "no" >&6; }
6571 if test "x$ac_ct_OTOOL64" = x; then
6572 OTOOL64=":"
6573 else
6574 case $cross_compiling:$ac_tool_warned in
6575 yes:)
6576 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6577 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6578 ac_tool_warned=yes ;;
6579 esac
6580 OTOOL64=$ac_ct_OTOOL64
6582 else
6583 OTOOL64="$ac_cv_prog_OTOOL64"
6612 { $as_echo "$as_me:$LINENO: checking for -single_module linker flag" >&5
6613 $as_echo_n "checking for -single_module linker flag... " >&6; }
6614 if test "${lt_cv_apple_cc_single_mod+set}" = set; then
6615 $as_echo_n "(cached) " >&6
6616 else
6617 lt_cv_apple_cc_single_mod=no
6618 if test -z "${LT_MULTI_MODULE}"; then
6619 # By default we will add the -single_module flag. You can override
6620 # by either setting the environment variable LT_MULTI_MODULE
6621 # non-empty at configure time, or by adding -multi_module to the
6622 # link flags.
6623 rm -rf libconftest.dylib*
6624 echo "int foo(void){return 1;}" > conftest.c
6625 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
6626 -dynamiclib -Wl,-single_module conftest.c" >&5
6627 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
6628 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
6629 _lt_result=$?
6630 if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
6631 lt_cv_apple_cc_single_mod=yes
6632 else
6633 cat conftest.err >&5
6635 rm -rf libconftest.dylib*
6636 rm -f conftest.*
6639 { $as_echo "$as_me:$LINENO: result: $lt_cv_apple_cc_single_mod" >&5
6640 $as_echo "$lt_cv_apple_cc_single_mod" >&6; }
6641 { $as_echo "$as_me:$LINENO: checking for -exported_symbols_list linker flag" >&5
6642 $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
6643 if test "${lt_cv_ld_exported_symbols_list+set}" = set; then
6644 $as_echo_n "(cached) " >&6
6645 else
6646 lt_cv_ld_exported_symbols_list=no
6647 save_LDFLAGS=$LDFLAGS
6648 echo "_main" > conftest.sym
6649 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
6650 cat >conftest.$ac_ext <<_ACEOF
6651 /* confdefs.h. */
6652 _ACEOF
6653 cat confdefs.h >>conftest.$ac_ext
6654 cat >>conftest.$ac_ext <<_ACEOF
6655 /* end confdefs.h. */
6658 main ()
6662 return 0;
6664 _ACEOF
6665 rm -f conftest.$ac_objext conftest$ac_exeext
6666 if { (ac_try="$ac_link"
6667 case "(($ac_try" in
6668 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6669 *) ac_try_echo=$ac_try;;
6670 esac
6671 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6672 $as_echo "$ac_try_echo") >&5
6673 (eval "$ac_link") 2>conftest.er1
6674 ac_status=$?
6675 grep -v '^ *+' conftest.er1 >conftest.err
6676 rm -f conftest.er1
6677 cat conftest.err >&5
6678 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6679 (exit $ac_status); } && {
6680 test -z "$ac_c_werror_flag" ||
6681 test ! -s conftest.err
6682 } && test -s conftest$ac_exeext && {
6683 test "$cross_compiling" = yes ||
6684 $as_test_x conftest$ac_exeext
6685 }; then
6686 lt_cv_ld_exported_symbols_list=yes
6687 else
6688 $as_echo "$as_me: failed program was:" >&5
6689 sed 's/^/| /' conftest.$ac_ext >&5
6691 lt_cv_ld_exported_symbols_list=no
6694 rm -rf conftest.dSYM
6695 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6696 conftest$ac_exeext conftest.$ac_ext
6697 LDFLAGS="$save_LDFLAGS"
6700 { $as_echo "$as_me:$LINENO: result: $lt_cv_ld_exported_symbols_list" >&5
6701 $as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
6702 case $host_os in
6703 rhapsody* | darwin1.[012])
6704 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
6705 darwin1.*)
6706 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
6707 darwin*) # darwin 5.x on
6708 # if running on 10.5 or later, the deployment target defaults
6709 # to the OS version, if on x86, and 10.4, the deployment
6710 # target defaults to 10.4. Don't you love it?
6711 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
6712 10.0,*86*-darwin8*|10.0,*-darwin[91]*)
6713 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
6714 10.[012]*)
6715 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
6716 10.*)
6717 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
6718 esac
6720 esac
6721 if test "$lt_cv_apple_cc_single_mod" = "yes"; then
6722 _lt_dar_single_mod='$single_module'
6724 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
6725 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
6726 else
6727 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
6729 if test "$DSYMUTIL" != ":"; then
6730 _lt_dsymutil='~$DSYMUTIL $lib || :'
6731 else
6732 _lt_dsymutil=
6735 esac
6738 { $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5
6739 $as_echo_n "checking for ANSI C header files... " >&6; }
6740 if test "${ac_cv_header_stdc+set}" = set; then
6741 $as_echo_n "(cached) " >&6
6742 else
6743 cat >conftest.$ac_ext <<_ACEOF
6744 /* confdefs.h. */
6745 _ACEOF
6746 cat confdefs.h >>conftest.$ac_ext
6747 cat >>conftest.$ac_ext <<_ACEOF
6748 /* end confdefs.h. */
6749 #include <stdlib.h>
6750 #include <stdarg.h>
6751 #include <string.h>
6752 #include <float.h>
6755 main ()
6759 return 0;
6761 _ACEOF
6762 rm -f conftest.$ac_objext
6763 if { (ac_try="$ac_compile"
6764 case "(($ac_try" in
6765 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6766 *) ac_try_echo=$ac_try;;
6767 esac
6768 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6769 $as_echo "$ac_try_echo") >&5
6770 (eval "$ac_compile") 2>conftest.er1
6771 ac_status=$?
6772 grep -v '^ *+' conftest.er1 >conftest.err
6773 rm -f conftest.er1
6774 cat conftest.err >&5
6775 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6776 (exit $ac_status); } && {
6777 test -z "$ac_c_werror_flag" ||
6778 test ! -s conftest.err
6779 } && test -s conftest.$ac_objext; then
6780 ac_cv_header_stdc=yes
6781 else
6782 $as_echo "$as_me: failed program was:" >&5
6783 sed 's/^/| /' conftest.$ac_ext >&5
6785 ac_cv_header_stdc=no
6788 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6790 if test $ac_cv_header_stdc = yes; then
6791 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6792 cat >conftest.$ac_ext <<_ACEOF
6793 /* confdefs.h. */
6794 _ACEOF
6795 cat confdefs.h >>conftest.$ac_ext
6796 cat >>conftest.$ac_ext <<_ACEOF
6797 /* end confdefs.h. */
6798 #include <string.h>
6800 _ACEOF
6801 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6802 $EGREP "memchr" >/dev/null 2>&1; then
6804 else
6805 ac_cv_header_stdc=no
6807 rm -f conftest*
6811 if test $ac_cv_header_stdc = yes; then
6812 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6813 cat >conftest.$ac_ext <<_ACEOF
6814 /* confdefs.h. */
6815 _ACEOF
6816 cat confdefs.h >>conftest.$ac_ext
6817 cat >>conftest.$ac_ext <<_ACEOF
6818 /* end confdefs.h. */
6819 #include <stdlib.h>
6821 _ACEOF
6822 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6823 $EGREP "free" >/dev/null 2>&1; then
6825 else
6826 ac_cv_header_stdc=no
6828 rm -f conftest*
6832 if test $ac_cv_header_stdc = yes; then
6833 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6834 if test "$cross_compiling" = yes; then
6836 else
6837 cat >conftest.$ac_ext <<_ACEOF
6838 /* confdefs.h. */
6839 _ACEOF
6840 cat confdefs.h >>conftest.$ac_ext
6841 cat >>conftest.$ac_ext <<_ACEOF
6842 /* end confdefs.h. */
6843 #include <ctype.h>
6844 #include <stdlib.h>
6845 #if ((' ' & 0x0FF) == 0x020)
6846 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6847 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6848 #else
6849 # define ISLOWER(c) \
6850 (('a' <= (c) && (c) <= 'i') \
6851 || ('j' <= (c) && (c) <= 'r') \
6852 || ('s' <= (c) && (c) <= 'z'))
6853 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6854 #endif
6856 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6858 main ()
6860 int i;
6861 for (i = 0; i < 256; i++)
6862 if (XOR (islower (i), ISLOWER (i))
6863 || toupper (i) != TOUPPER (i))
6864 return 2;
6865 return 0;
6867 _ACEOF
6868 rm -f conftest$ac_exeext
6869 if { (ac_try="$ac_link"
6870 case "(($ac_try" in
6871 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6872 *) ac_try_echo=$ac_try;;
6873 esac
6874 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6875 $as_echo "$ac_try_echo") >&5
6876 (eval "$ac_link") 2>&5
6877 ac_status=$?
6878 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6879 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6880 { (case "(($ac_try" in
6881 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6882 *) ac_try_echo=$ac_try;;
6883 esac
6884 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6885 $as_echo "$ac_try_echo") >&5
6886 (eval "$ac_try") 2>&5
6887 ac_status=$?
6888 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6889 (exit $ac_status); }; }; then
6891 else
6892 $as_echo "$as_me: program exited with status $ac_status" >&5
6893 $as_echo "$as_me: failed program was:" >&5
6894 sed 's/^/| /' conftest.$ac_ext >&5
6896 ( exit $ac_status )
6897 ac_cv_header_stdc=no
6899 rm -rf conftest.dSYM
6900 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6906 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
6907 $as_echo "$ac_cv_header_stdc" >&6; }
6908 if test $ac_cv_header_stdc = yes; then
6910 cat >>confdefs.h <<\_ACEOF
6911 #define STDC_HEADERS 1
6912 _ACEOF
6916 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6926 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6927 inttypes.h stdint.h unistd.h
6929 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6930 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
6931 $as_echo_n "checking for $ac_header... " >&6; }
6932 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
6933 $as_echo_n "(cached) " >&6
6934 else
6935 cat >conftest.$ac_ext <<_ACEOF
6936 /* confdefs.h. */
6937 _ACEOF
6938 cat confdefs.h >>conftest.$ac_ext
6939 cat >>conftest.$ac_ext <<_ACEOF
6940 /* end confdefs.h. */
6941 $ac_includes_default
6943 #include <$ac_header>
6944 _ACEOF
6945 rm -f conftest.$ac_objext
6946 if { (ac_try="$ac_compile"
6947 case "(($ac_try" in
6948 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6949 *) ac_try_echo=$ac_try;;
6950 esac
6951 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6952 $as_echo "$ac_try_echo") >&5
6953 (eval "$ac_compile") 2>conftest.er1
6954 ac_status=$?
6955 grep -v '^ *+' conftest.er1 >conftest.err
6956 rm -f conftest.er1
6957 cat conftest.err >&5
6958 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6959 (exit $ac_status); } && {
6960 test -z "$ac_c_werror_flag" ||
6961 test ! -s conftest.err
6962 } && test -s conftest.$ac_objext; then
6963 eval "$as_ac_Header=yes"
6964 else
6965 $as_echo "$as_me: failed program was:" >&5
6966 sed 's/^/| /' conftest.$ac_ext >&5
6968 eval "$as_ac_Header=no"
6971 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6973 ac_res=`eval 'as_val=${'$as_ac_Header'}
6974 $as_echo "$as_val"'`
6975 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
6976 $as_echo "$ac_res" >&6; }
6977 as_val=`eval 'as_val=${'$as_ac_Header'}
6978 $as_echo "$as_val"'`
6979 if test "x$as_val" = x""yes; then
6980 cat >>confdefs.h <<_ACEOF
6981 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6982 _ACEOF
6986 done
6990 for ac_header in dlfcn.h
6992 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6993 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
6994 $as_echo_n "checking for $ac_header... " >&6; }
6995 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
6996 $as_echo_n "(cached) " >&6
6997 else
6998 cat >conftest.$ac_ext <<_ACEOF
6999 /* confdefs.h. */
7000 _ACEOF
7001 cat confdefs.h >>conftest.$ac_ext
7002 cat >>conftest.$ac_ext <<_ACEOF
7003 /* end confdefs.h. */
7004 $ac_includes_default
7006 #include <$ac_header>
7007 _ACEOF
7008 rm -f conftest.$ac_objext
7009 if { (ac_try="$ac_compile"
7010 case "(($ac_try" in
7011 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7012 *) ac_try_echo=$ac_try;;
7013 esac
7014 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7015 $as_echo "$ac_try_echo") >&5
7016 (eval "$ac_compile") 2>conftest.er1
7017 ac_status=$?
7018 grep -v '^ *+' conftest.er1 >conftest.err
7019 rm -f conftest.er1
7020 cat conftest.err >&5
7021 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7022 (exit $ac_status); } && {
7023 test -z "$ac_c_werror_flag" ||
7024 test ! -s conftest.err
7025 } && test -s conftest.$ac_objext; then
7026 eval "$as_ac_Header=yes"
7027 else
7028 $as_echo "$as_me: failed program was:" >&5
7029 sed 's/^/| /' conftest.$ac_ext >&5
7031 eval "$as_ac_Header=no"
7034 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7036 ac_res=`eval 'as_val=${'$as_ac_Header'}
7037 $as_echo "$as_val"'`
7038 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
7039 $as_echo "$ac_res" >&6; }
7040 as_val=`eval 'as_val=${'$as_ac_Header'}
7041 $as_echo "$as_val"'`
7042 if test "x$as_val" = x""yes; then
7043 cat >>confdefs.h <<_ACEOF
7044 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7045 _ACEOF
7049 done
7053 # Set options
7054 # Check whether --enable-shared was given.
7055 if test "${enable_shared+set}" = set; then
7056 enableval=$enable_shared; p=${PACKAGE-default}
7057 case $enableval in
7058 yes) enable_shared=yes ;;
7059 no) enable_shared=no ;;
7061 enable_shared=no
7062 # Look at the argument we got. We use all the common list separators.
7063 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
7064 for pkg in $enableval; do
7065 IFS="$lt_save_ifs"
7066 if test "X$pkg" = "X$p"; then
7067 enable_shared=yes
7069 done
7070 IFS="$lt_save_ifs"
7072 esac
7073 else
7074 enable_shared=no
7086 enable_dlopen=no
7089 enable_win32_dll=no
7093 # Check whether --enable-static was given.
7094 if test "${enable_static+set}" = set; then
7095 enableval=$enable_static; p=${PACKAGE-default}
7096 case $enableval in
7097 yes) enable_static=yes ;;
7098 no) enable_static=no ;;
7100 enable_static=no
7101 # Look at the argument we got. We use all the common list separators.
7102 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
7103 for pkg in $enableval; do
7104 IFS="$lt_save_ifs"
7105 if test "X$pkg" = "X$p"; then
7106 enable_static=yes
7108 done
7109 IFS="$lt_save_ifs"
7111 esac
7112 else
7113 enable_static=yes
7125 # Check whether --with-pic was given.
7126 if test "${with_pic+set}" = set; then
7127 withval=$with_pic; pic_mode="$withval"
7128 else
7129 pic_mode=default
7133 test -z "$pic_mode" && pic_mode=default
7141 # Check whether --enable-fast-install was given.
7142 if test "${enable_fast_install+set}" = set; then
7143 enableval=$enable_fast_install; p=${PACKAGE-default}
7144 case $enableval in
7145 yes) enable_fast_install=yes ;;
7146 no) enable_fast_install=no ;;
7148 enable_fast_install=no
7149 # Look at the argument we got. We use all the common list separators.
7150 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
7151 for pkg in $enableval; do
7152 IFS="$lt_save_ifs"
7153 if test "X$pkg" = "X$p"; then
7154 enable_fast_install=yes
7156 done
7157 IFS="$lt_save_ifs"
7159 esac
7160 else
7161 enable_fast_install=yes
7174 # This can be used to rebuild libtool when needed
7175 LIBTOOL_DEPS="$ltmain"
7177 # Always use our own libtool.
7178 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
7204 test -z "$LN_S" && LN_S="ln -s"
7219 if test -n "${ZSH_VERSION+set}" ; then
7220 setopt NO_GLOB_SUBST
7223 { $as_echo "$as_me:$LINENO: checking for objdir" >&5
7224 $as_echo_n "checking for objdir... " >&6; }
7225 if test "${lt_cv_objdir+set}" = set; then
7226 $as_echo_n "(cached) " >&6
7227 else
7228 rm -f .libs 2>/dev/null
7229 mkdir .libs 2>/dev/null
7230 if test -d .libs; then
7231 lt_cv_objdir=.libs
7232 else
7233 # MS-DOS does not allow filenames that begin with a dot.
7234 lt_cv_objdir=_libs
7236 rmdir .libs 2>/dev/null
7238 { $as_echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5
7239 $as_echo "$lt_cv_objdir" >&6; }
7240 objdir=$lt_cv_objdir
7246 cat >>confdefs.h <<_ACEOF
7247 #define LT_OBJDIR "$lt_cv_objdir/"
7248 _ACEOF
7266 case $host_os in
7267 aix3*)
7268 # AIX sometimes has problems with the GCC collect2 program. For some
7269 # reason, if we set the COLLECT_NAMES environment variable, the problems
7270 # vanish in a puff of smoke.
7271 if test "X${COLLECT_NAMES+set}" != Xset; then
7272 COLLECT_NAMES=
7273 export COLLECT_NAMES
7276 esac
7278 # Sed substitution that helps us do robust quoting. It backslashifies
7279 # metacharacters that are still active within double-quoted strings.
7280 sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
7282 # Same as above, but do not quote variable references.
7283 double_quote_subst='s/\(["`\\]\)/\\\1/g'
7285 # Sed substitution to delay expansion of an escaped shell variable in a
7286 # double_quote_subst'ed string.
7287 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
7289 # Sed substitution to delay expansion of an escaped single quote.
7290 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
7292 # Sed substitution to avoid accidental globbing in evaled expressions
7293 no_glob_subst='s/\*/\\\*/g'
7295 # Global variables:
7296 ofile=libtool
7297 can_build_shared=yes
7299 # All known linkers require a `.a' archive for static linking (except MSVC,
7300 # which needs '.lib').
7301 libext=a
7303 with_gnu_ld="$lt_cv_prog_gnu_ld"
7305 old_CC="$CC"
7306 old_CFLAGS="$CFLAGS"
7308 # Set sane defaults for various variables
7309 test -z "$CC" && CC=cc
7310 test -z "$LTCC" && LTCC=$CC
7311 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
7312 test -z "$LD" && LD=ld
7313 test -z "$ac_objext" && ac_objext=o
7315 for cc_temp in $compiler""; do
7316 case $cc_temp in
7317 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
7318 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
7319 \-*) ;;
7320 *) break;;
7321 esac
7322 done
7323 cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
7326 # Only perform the check for file, if the check method requires it
7327 test -z "$MAGIC_CMD" && MAGIC_CMD=file
7328 case $deplibs_check_method in
7329 file_magic*)
7330 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
7331 { $as_echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5
7332 $as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
7333 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
7334 $as_echo_n "(cached) " >&6
7335 else
7336 case $MAGIC_CMD in
7337 [\\/*] | ?:[\\/]*)
7338 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
7341 lt_save_MAGIC_CMD="$MAGIC_CMD"
7342 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
7343 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
7344 for ac_dir in $ac_dummy; do
7345 IFS="$lt_save_ifs"
7346 test -z "$ac_dir" && ac_dir=.
7347 if test -f $ac_dir/${ac_tool_prefix}file; then
7348 lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
7349 if test -n "$file_magic_test_file"; then
7350 case $deplibs_check_method in
7351 "file_magic "*)
7352 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
7353 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7354 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
7355 $EGREP "$file_magic_regex" > /dev/null; then
7357 else
7358 cat <<_LT_EOF 1>&2
7360 *** Warning: the command libtool uses to detect shared libraries,
7361 *** $file_magic_cmd, produces output that libtool cannot recognize.
7362 *** The result is that libtool may fail to recognize shared libraries
7363 *** as such. This will affect the creation of libtool libraries that
7364 *** depend on shared libraries, but programs linked with such libtool
7365 *** libraries will work regardless of this problem. Nevertheless, you
7366 *** may want to report the problem to your system manager and/or to
7367 *** bug-libtool@gnu.org
7369 _LT_EOF
7370 fi ;;
7371 esac
7373 break
7375 done
7376 IFS="$lt_save_ifs"
7377 MAGIC_CMD="$lt_save_MAGIC_CMD"
7379 esac
7382 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7383 if test -n "$MAGIC_CMD"; then
7384 { $as_echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
7385 $as_echo "$MAGIC_CMD" >&6; }
7386 else
7387 { $as_echo "$as_me:$LINENO: result: no" >&5
7388 $as_echo "no" >&6; }
7395 if test -z "$lt_cv_path_MAGIC_CMD"; then
7396 if test -n "$ac_tool_prefix"; then
7397 { $as_echo "$as_me:$LINENO: checking for file" >&5
7398 $as_echo_n "checking for file... " >&6; }
7399 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
7400 $as_echo_n "(cached) " >&6
7401 else
7402 case $MAGIC_CMD in
7403 [\\/*] | ?:[\\/]*)
7404 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
7407 lt_save_MAGIC_CMD="$MAGIC_CMD"
7408 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
7409 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
7410 for ac_dir in $ac_dummy; do
7411 IFS="$lt_save_ifs"
7412 test -z "$ac_dir" && ac_dir=.
7413 if test -f $ac_dir/file; then
7414 lt_cv_path_MAGIC_CMD="$ac_dir/file"
7415 if test -n "$file_magic_test_file"; then
7416 case $deplibs_check_method in
7417 "file_magic "*)
7418 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
7419 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7420 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
7421 $EGREP "$file_magic_regex" > /dev/null; then
7423 else
7424 cat <<_LT_EOF 1>&2
7426 *** Warning: the command libtool uses to detect shared libraries,
7427 *** $file_magic_cmd, produces output that libtool cannot recognize.
7428 *** The result is that libtool may fail to recognize shared libraries
7429 *** as such. This will affect the creation of libtool libraries that
7430 *** depend on shared libraries, but programs linked with such libtool
7431 *** libraries will work regardless of this problem. Nevertheless, you
7432 *** may want to report the problem to your system manager and/or to
7433 *** bug-libtool@gnu.org
7435 _LT_EOF
7436 fi ;;
7437 esac
7439 break
7441 done
7442 IFS="$lt_save_ifs"
7443 MAGIC_CMD="$lt_save_MAGIC_CMD"
7445 esac
7448 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7449 if test -n "$MAGIC_CMD"; then
7450 { $as_echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
7451 $as_echo "$MAGIC_CMD" >&6; }
7452 else
7453 { $as_echo "$as_me:$LINENO: result: no" >&5
7454 $as_echo "no" >&6; }
7458 else
7459 MAGIC_CMD=:
7465 esac
7467 # Use C for the default configuration in the libtool script
7469 lt_save_CC="$CC"
7470 ac_ext=c
7471 ac_cpp='$CPP $CPPFLAGS'
7472 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7473 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7474 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7477 # Source file extension for C test sources.
7478 ac_ext=c
7480 # Object file extension for compiled C test sources.
7481 objext=o
7482 objext=$objext
7484 # Code to be used in simple compile tests
7485 lt_simple_compile_test_code="int some_variable = 0;"
7487 # Code to be used in simple link tests
7488 lt_simple_link_test_code='int main(){return(0);}'
7496 # If no C compiler was specified, use CC.
7497 LTCC=${LTCC-"$CC"}
7499 # If no C compiler flags were specified, use CFLAGS.
7500 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
7502 # Allow CC to be a program name with arguments.
7503 compiler=$CC
7505 # Save the default compiler, since it gets overwritten when the other
7506 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
7507 compiler_DEFAULT=$CC
7509 # save warnings/boilerplate of simple test code
7510 ac_outfile=conftest.$ac_objext
7511 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
7512 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
7513 _lt_compiler_boilerplate=`cat conftest.err`
7514 $RM conftest*
7516 ac_outfile=conftest.$ac_objext
7517 echo "$lt_simple_link_test_code" >conftest.$ac_ext
7518 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
7519 _lt_linker_boilerplate=`cat conftest.err`
7520 $RM -r conftest*
7523 ## CAVEAT EMPTOR:
7524 ## There is no encapsulation within the following macros, do not change
7525 ## the running order or otherwise move them around unless you know exactly
7526 ## what you are doing...
7527 if test -n "$compiler"; then
7529 lt_prog_compiler_no_builtin_flag=
7531 if test "$GCC" = yes; then
7532 lt_prog_compiler_no_builtin_flag=' -fno-builtin'
7534 { $as_echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
7535 $as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
7536 if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then
7537 $as_echo_n "(cached) " >&6
7538 else
7539 lt_cv_prog_compiler_rtti_exceptions=no
7540 ac_outfile=conftest.$ac_objext
7541 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
7542 lt_compiler_flag="-fno-rtti -fno-exceptions"
7543 # Insert the option either (1) after the last *FLAGS variable, or
7544 # (2) before a word containing "conftest.", or (3) at the end.
7545 # Note that $ac_compile itself does not contain backslashes and begins
7546 # with a dollar sign (not a hyphen), so the echo should work correctly.
7547 # The option is referenced via a variable to avoid confusing sed.
7548 lt_compile=`echo "$ac_compile" | $SED \
7549 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7550 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7551 -e 's:$: $lt_compiler_flag:'`
7552 (eval echo "\"\$as_me:7552: $lt_compile\"" >&5)
7553 (eval "$lt_compile" 2>conftest.err)
7554 ac_status=$?
7555 cat conftest.err >&5
7556 echo "$as_me:7556: \$? = $ac_status" >&5
7557 if (exit $ac_status) && test -s "$ac_outfile"; then
7558 # The compiler can only warn and ignore the option if not recognized
7559 # So say no if there are warnings other than the usual output.
7560 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
7561 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
7562 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
7563 lt_cv_prog_compiler_rtti_exceptions=yes
7566 $RM conftest*
7569 { $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
7570 $as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
7572 if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
7573 lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
7574 else
7585 lt_prog_compiler_wl=
7586 lt_prog_compiler_pic=
7587 lt_prog_compiler_static=
7589 { $as_echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
7590 $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
7592 if test "$GCC" = yes; then
7593 lt_prog_compiler_wl='-Wl,'
7594 lt_prog_compiler_static='-static'
7596 case $host_os in
7597 aix*)
7598 # All AIX code is PIC.
7599 if test "$host_cpu" = ia64; then
7600 # AIX 5 now supports IA64 processor
7601 lt_prog_compiler_static='-Bstatic'
7605 amigaos*)
7606 case $host_cpu in
7607 powerpc)
7608 # see comment about AmigaOS4 .so support
7609 lt_prog_compiler_pic='-fPIC'
7611 m68k)
7612 # FIXME: we need at least 68020 code to build shared libraries, but
7613 # adding the `-m68020' flag to GCC prevents building anything better,
7614 # like `-m68040'.
7615 lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
7617 esac
7620 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
7621 # PIC is the default for these OSes.
7624 mingw* | cygwin* | pw32* | os2* | cegcc*)
7625 # This hack is so that the source file can tell whether it is being
7626 # built for inclusion in a dll (and should export symbols for example).
7627 # Although the cygwin gcc ignores -fPIC, still need this for old-style
7628 # (--disable-auto-import) libraries
7629 lt_prog_compiler_pic='-DDLL_EXPORT'
7632 darwin* | rhapsody*)
7633 # PIC is the default on this platform
7634 # Common symbols not allowed in MH_DYLIB files
7635 lt_prog_compiler_pic='-fno-common'
7638 hpux*)
7639 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
7640 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
7641 # sets the default TLS model and affects inlining.
7642 case $host_cpu in
7643 hppa*64*)
7644 # +Z the default
7647 lt_prog_compiler_pic='-fPIC'
7649 esac
7652 interix[3-9]*)
7653 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
7654 # Instead, we relocate shared libraries at runtime.
7657 msdosdjgpp*)
7658 # Just because we use GCC doesn't mean we suddenly get shared libraries
7659 # on systems that don't support them.
7660 lt_prog_compiler_can_build_shared=no
7661 enable_shared=no
7664 *nto* | *qnx*)
7665 # QNX uses GNU C++, but need to define -shared option too, otherwise
7666 # it will coredump.
7667 lt_prog_compiler_pic='-fPIC -shared'
7670 sysv4*MP*)
7671 if test -d /usr/nec; then
7672 lt_prog_compiler_pic=-Kconform_pic
7677 lt_prog_compiler_pic='-fPIC'
7679 esac
7680 else
7681 # PORTME Check for flag to pass linker flags through the system compiler.
7682 case $host_os in
7683 aix*)
7684 lt_prog_compiler_wl='-Wl,'
7685 if test "$host_cpu" = ia64; then
7686 # AIX 5 now supports IA64 processor
7687 lt_prog_compiler_static='-Bstatic'
7688 else
7689 lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
7693 mingw* | cygwin* | pw32* | os2* | cegcc*)
7694 # This hack is so that the source file can tell whether it is being
7695 # built for inclusion in a dll (and should export symbols for example).
7696 lt_prog_compiler_pic='-DDLL_EXPORT'
7699 hpux9* | hpux10* | hpux11*)
7700 lt_prog_compiler_wl='-Wl,'
7701 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
7702 # not for PA HP-UX.
7703 case $host_cpu in
7704 hppa*64*|ia64*)
7705 # +Z the default
7708 lt_prog_compiler_pic='+Z'
7710 esac
7711 # Is there a better lt_prog_compiler_static that works with the bundled CC?
7712 lt_prog_compiler_static='${wl}-a ${wl}archive'
7715 irix5* | irix6* | nonstopux*)
7716 lt_prog_compiler_wl='-Wl,'
7717 # PIC (with -KPIC) is the default.
7718 lt_prog_compiler_static='-non_shared'
7721 linux* | k*bsd*-gnu)
7722 case $cc_basename in
7723 # old Intel for x86_64 which still supported -KPIC.
7724 ecc*)
7725 lt_prog_compiler_wl='-Wl,'
7726 lt_prog_compiler_pic='-KPIC'
7727 lt_prog_compiler_static='-static'
7729 # icc used to be incompatible with GCC.
7730 # ICC 10 doesn't accept -KPIC any more.
7731 icc* | ifort*)
7732 lt_prog_compiler_wl='-Wl,'
7733 lt_prog_compiler_pic='-fPIC'
7734 lt_prog_compiler_static='-static'
7736 # Lahey Fortran 8.1.
7737 lf95*)
7738 lt_prog_compiler_wl='-Wl,'
7739 lt_prog_compiler_pic='--shared'
7740 lt_prog_compiler_static='--static'
7742 pgcc* | pgf77* | pgf90* | pgf95*)
7743 # Portland Group compilers (*not* the Pentium gcc compiler,
7744 # which looks to be a dead project)
7745 lt_prog_compiler_wl='-Wl,'
7746 lt_prog_compiler_pic='-fpic'
7747 lt_prog_compiler_static='-Bstatic'
7749 ccc*)
7750 lt_prog_compiler_wl='-Wl,'
7751 # All Alpha code is PIC.
7752 lt_prog_compiler_static='-non_shared'
7754 xl*)
7755 # IBM XL C 8.0/Fortran 10.1 on PPC
7756 lt_prog_compiler_wl='-Wl,'
7757 lt_prog_compiler_pic='-qpic'
7758 lt_prog_compiler_static='-qstaticlink'
7761 case `$CC -V 2>&1 | sed 5q` in
7762 *Sun\ C*)
7763 # Sun C 5.9
7764 lt_prog_compiler_pic='-KPIC'
7765 lt_prog_compiler_static='-Bstatic'
7766 lt_prog_compiler_wl='-Wl,'
7768 *Sun\ F*)
7769 # Sun Fortran 8.3 passes all unrecognized flags to the linker
7770 lt_prog_compiler_pic='-KPIC'
7771 lt_prog_compiler_static='-Bstatic'
7772 lt_prog_compiler_wl=''
7774 esac
7776 esac
7779 newsos6)
7780 lt_prog_compiler_pic='-KPIC'
7781 lt_prog_compiler_static='-Bstatic'
7784 *nto* | *qnx*)
7785 # QNX uses GNU C++, but need to define -shared option too, otherwise
7786 # it will coredump.
7787 lt_prog_compiler_pic='-fPIC -shared'
7790 osf3* | osf4* | osf5*)
7791 lt_prog_compiler_wl='-Wl,'
7792 # All OSF/1 code is PIC.
7793 lt_prog_compiler_static='-non_shared'
7796 rdos*)
7797 lt_prog_compiler_static='-non_shared'
7800 solaris*)
7801 lt_prog_compiler_pic='-KPIC'
7802 lt_prog_compiler_static='-Bstatic'
7803 case $cc_basename in
7804 f77* | f90* | f95*)
7805 lt_prog_compiler_wl='-Qoption ld ';;
7807 lt_prog_compiler_wl='-Wl,';;
7808 esac
7811 sunos4*)
7812 lt_prog_compiler_wl='-Qoption ld '
7813 lt_prog_compiler_pic='-PIC'
7814 lt_prog_compiler_static='-Bstatic'
7817 sysv4 | sysv4.2uw2* | sysv4.3*)
7818 lt_prog_compiler_wl='-Wl,'
7819 lt_prog_compiler_pic='-KPIC'
7820 lt_prog_compiler_static='-Bstatic'
7823 sysv4*MP*)
7824 if test -d /usr/nec ;then
7825 lt_prog_compiler_pic='-Kconform_pic'
7826 lt_prog_compiler_static='-Bstatic'
7830 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
7831 lt_prog_compiler_wl='-Wl,'
7832 lt_prog_compiler_pic='-KPIC'
7833 lt_prog_compiler_static='-Bstatic'
7836 unicos*)
7837 lt_prog_compiler_wl='-Wl,'
7838 lt_prog_compiler_can_build_shared=no
7841 uts4*)
7842 lt_prog_compiler_pic='-pic'
7843 lt_prog_compiler_static='-Bstatic'
7847 lt_prog_compiler_can_build_shared=no
7849 esac
7852 case $host_os in
7853 # For platforms which do not support PIC, -DPIC is meaningless:
7854 *djgpp*)
7855 lt_prog_compiler_pic=
7858 lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
7860 esac
7861 { $as_echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5
7862 $as_echo "$lt_prog_compiler_pic" >&6; }
7870 # Check to make sure the PIC flag actually works.
7872 if test -n "$lt_prog_compiler_pic"; then
7873 { $as_echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
7874 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
7875 if test "${lt_cv_prog_compiler_pic_works+set}" = set; then
7876 $as_echo_n "(cached) " >&6
7877 else
7878 lt_cv_prog_compiler_pic_works=no
7879 ac_outfile=conftest.$ac_objext
7880 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
7881 lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
7882 # Insert the option either (1) after the last *FLAGS variable, or
7883 # (2) before a word containing "conftest.", or (3) at the end.
7884 # Note that $ac_compile itself does not contain backslashes and begins
7885 # with a dollar sign (not a hyphen), so the echo should work correctly.
7886 # The option is referenced via a variable to avoid confusing sed.
7887 lt_compile=`echo "$ac_compile" | $SED \
7888 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7889 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7890 -e 's:$: $lt_compiler_flag:'`
7891 (eval echo "\"\$as_me:7891: $lt_compile\"" >&5)
7892 (eval "$lt_compile" 2>conftest.err)
7893 ac_status=$?
7894 cat conftest.err >&5
7895 echo "$as_me:7895: \$? = $ac_status" >&5
7896 if (exit $ac_status) && test -s "$ac_outfile"; then
7897 # The compiler can only warn and ignore the option if not recognized
7898 # So say no if there are warnings other than the usual output.
7899 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
7900 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
7901 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
7902 lt_cv_prog_compiler_pic_works=yes
7905 $RM conftest*
7908 { $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works" >&5
7909 $as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
7911 if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
7912 case $lt_prog_compiler_pic in
7913 "" | " "*) ;;
7914 *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
7915 esac
7916 else
7917 lt_prog_compiler_pic=
7918 lt_prog_compiler_can_build_shared=no
7929 # Check to make sure the static flag actually works.
7931 wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
7932 { $as_echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5
7933 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
7934 if test "${lt_cv_prog_compiler_static_works+set}" = set; then
7935 $as_echo_n "(cached) " >&6
7936 else
7937 lt_cv_prog_compiler_static_works=no
7938 save_LDFLAGS="$LDFLAGS"
7939 LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
7940 echo "$lt_simple_link_test_code" > conftest.$ac_ext
7941 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
7942 # The linker can only warn and ignore the option if not recognized
7943 # So say no if there are warnings
7944 if test -s conftest.err; then
7945 # Append any errors to the config.log.
7946 cat conftest.err 1>&5
7947 $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
7948 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
7949 if diff conftest.exp conftest.er2 >/dev/null; then
7950 lt_cv_prog_compiler_static_works=yes
7952 else
7953 lt_cv_prog_compiler_static_works=yes
7956 $RM -r conftest*
7957 LDFLAGS="$save_LDFLAGS"
7960 { $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works" >&5
7961 $as_echo "$lt_cv_prog_compiler_static_works" >&6; }
7963 if test x"$lt_cv_prog_compiler_static_works" = xyes; then
7965 else
7966 lt_prog_compiler_static=
7975 { $as_echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
7976 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
7977 if test "${lt_cv_prog_compiler_c_o+set}" = set; then
7978 $as_echo_n "(cached) " >&6
7979 else
7980 lt_cv_prog_compiler_c_o=no
7981 $RM -r conftest 2>/dev/null
7982 mkdir conftest
7983 cd conftest
7984 mkdir out
7985 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
7987 lt_compiler_flag="-o out/conftest2.$ac_objext"
7988 # Insert the option either (1) after the last *FLAGS variable, or
7989 # (2) before a word containing "conftest.", or (3) at the end.
7990 # Note that $ac_compile itself does not contain backslashes and begins
7991 # with a dollar sign (not a hyphen), so the echo should work correctly.
7992 lt_compile=`echo "$ac_compile" | $SED \
7993 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7994 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7995 -e 's:$: $lt_compiler_flag:'`
7996 (eval echo "\"\$as_me:7996: $lt_compile\"" >&5)
7997 (eval "$lt_compile" 2>out/conftest.err)
7998 ac_status=$?
7999 cat out/conftest.err >&5
8000 echo "$as_me:8000: \$? = $ac_status" >&5
8001 if (exit $ac_status) && test -s out/conftest2.$ac_objext
8002 then
8003 # The compiler can only warn and ignore the option if not recognized
8004 # So say no if there are warnings
8005 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
8006 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
8007 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
8008 lt_cv_prog_compiler_c_o=yes
8011 chmod u+w . 2>&5
8012 $RM conftest*
8013 # SGI C++ compiler will create directory out/ii_files/ for
8014 # template instantiation
8015 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
8016 $RM out/* && rmdir out
8017 cd ..
8018 $RM -r conftest
8019 $RM conftest*
8022 { $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5
8023 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
8030 { $as_echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
8031 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
8032 if test "${lt_cv_prog_compiler_c_o+set}" = set; then
8033 $as_echo_n "(cached) " >&6
8034 else
8035 lt_cv_prog_compiler_c_o=no
8036 $RM -r conftest 2>/dev/null
8037 mkdir conftest
8038 cd conftest
8039 mkdir out
8040 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
8042 lt_compiler_flag="-o out/conftest2.$ac_objext"
8043 # Insert the option either (1) after the last *FLAGS variable, or
8044 # (2) before a word containing "conftest.", or (3) at the end.
8045 # Note that $ac_compile itself does not contain backslashes and begins
8046 # with a dollar sign (not a hyphen), so the echo should work correctly.
8047 lt_compile=`echo "$ac_compile" | $SED \
8048 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
8049 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
8050 -e 's:$: $lt_compiler_flag:'`
8051 (eval echo "\"\$as_me:8051: $lt_compile\"" >&5)
8052 (eval "$lt_compile" 2>out/conftest.err)
8053 ac_status=$?
8054 cat out/conftest.err >&5
8055 echo "$as_me:8055: \$? = $ac_status" >&5
8056 if (exit $ac_status) && test -s out/conftest2.$ac_objext
8057 then
8058 # The compiler can only warn and ignore the option if not recognized
8059 # So say no if there are warnings
8060 $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
8061 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
8062 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
8063 lt_cv_prog_compiler_c_o=yes
8066 chmod u+w . 2>&5
8067 $RM conftest*
8068 # SGI C++ compiler will create directory out/ii_files/ for
8069 # template instantiation
8070 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
8071 $RM out/* && rmdir out
8072 cd ..
8073 $RM -r conftest
8074 $RM conftest*
8077 { $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5
8078 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
8083 hard_links="nottested"
8084 if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
8085 # do not overwrite the value of need_locks provided by the user
8086 { $as_echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
8087 $as_echo_n "checking if we can lock with hard links... " >&6; }
8088 hard_links=yes
8089 $RM conftest*
8090 ln conftest.a conftest.b 2>/dev/null && hard_links=no
8091 touch conftest.a
8092 ln conftest.a conftest.b 2>&5 || hard_links=no
8093 ln conftest.a conftest.b 2>/dev/null && hard_links=no
8094 { $as_echo "$as_me:$LINENO: result: $hard_links" >&5
8095 $as_echo "$hard_links" >&6; }
8096 if test "$hard_links" = no; then
8097 { $as_echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
8098 $as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
8099 need_locks=warn
8101 else
8102 need_locks=no
8110 { $as_echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
8111 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
8113 runpath_var=
8114 allow_undefined_flag=
8115 always_export_symbols=no
8116 archive_cmds=
8117 archive_expsym_cmds=
8118 compiler_needs_object=no
8119 enable_shared_with_static_runtimes=no
8120 export_dynamic_flag_spec=
8121 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
8122 hardcode_automatic=no
8123 hardcode_direct=no
8124 hardcode_direct_absolute=no
8125 hardcode_libdir_flag_spec=
8126 hardcode_libdir_flag_spec_ld=
8127 hardcode_libdir_separator=
8128 hardcode_minus_L=no
8129 hardcode_shlibpath_var=unsupported
8130 inherit_rpath=no
8131 link_all_deplibs=unknown
8132 module_cmds=
8133 module_expsym_cmds=
8134 old_archive_from_new_cmds=
8135 old_archive_from_expsyms_cmds=
8136 thread_safe_flag_spec=
8137 whole_archive_flag_spec=
8138 # include_expsyms should be a list of space-separated symbols to be *always*
8139 # included in the symbol list
8140 include_expsyms=
8141 # exclude_expsyms can be an extended regexp of symbols to exclude
8142 # it will be wrapped by ` (' and `)$', so one must not match beginning or
8143 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
8144 # as well as any symbol that contains `d'.
8145 exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
8146 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
8147 # platforms (ab)use it in PIC code, but their linkers get confused if
8148 # the symbol is explicitly referenced. Since portable code cannot
8149 # rely on this symbol name, it's probably fine to never include it in
8150 # preloaded symbol tables.
8151 # Exclude shared library initialization/finalization symbols.
8152 extract_expsyms_cmds=
8154 case $host_os in
8155 cygwin* | mingw* | pw32* | cegcc*)
8156 # FIXME: the MSVC++ port hasn't been tested in a loooong time
8157 # When not using gcc, we currently assume that we are using
8158 # Microsoft Visual C++.
8159 if test "$GCC" != yes; then
8160 with_gnu_ld=no
8163 interix*)
8164 # we just hope/assume this is gcc and not c89 (= MSVC++)
8165 with_gnu_ld=yes
8167 openbsd*)
8168 with_gnu_ld=no
8170 esac
8172 ld_shlibs=yes
8173 if test "$with_gnu_ld" = yes; then
8174 # If archive_cmds runs LD, not CC, wlarc should be empty
8175 wlarc='${wl}'
8177 # Set some defaults for GNU ld with shared library support. These
8178 # are reset later if shared libraries are not supported. Putting them
8179 # here allows them to be overridden if necessary.
8180 runpath_var=LD_RUN_PATH
8181 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8182 export_dynamic_flag_spec='${wl}--export-dynamic'
8183 # ancient GNU ld didn't support --whole-archive et. al.
8184 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
8185 whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
8186 else
8187 whole_archive_flag_spec=
8189 supports_anon_versioning=no
8190 case `$LD -v 2>&1` in
8191 *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
8192 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
8193 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
8194 *\ 2.11.*) ;; # other 2.11 versions
8195 *) supports_anon_versioning=yes ;;
8196 esac
8198 # See if GNU ld supports shared libraries.
8199 case $host_os in
8200 aix[3-9]*)
8201 # On AIX/PPC, the GNU linker is very broken
8202 if test "$host_cpu" != ia64; then
8203 ld_shlibs=no
8204 cat <<_LT_EOF 1>&2
8206 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
8207 *** to be unable to reliably create shared libraries on AIX.
8208 *** Therefore, libtool is disabling shared libraries support. If you
8209 *** really care for shared libraries, you may want to modify your PATH
8210 *** so that a non-GNU linker is found, and then restart.
8212 _LT_EOF
8216 amigaos*)
8217 case $host_cpu in
8218 powerpc)
8219 # see comment about AmigaOS4 .so support
8220 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8221 archive_expsym_cmds=''
8223 m68k)
8224 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)'
8225 hardcode_libdir_flag_spec='-L$libdir'
8226 hardcode_minus_L=yes
8228 esac
8231 beos*)
8232 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
8233 allow_undefined_flag=unsupported
8234 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
8235 # support --undefined. This deserves some investigation. FIXME
8236 archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8237 else
8238 ld_shlibs=no
8242 cygwin* | mingw* | pw32* | cegcc*)
8243 # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
8244 # as there is no search path for DLLs.
8245 hardcode_libdir_flag_spec='-L$libdir'
8246 allow_undefined_flag=unsupported
8247 always_export_symbols=no
8248 enable_shared_with_static_runtimes=yes
8249 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
8251 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
8252 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
8253 # If the export-symbols file already is a .def file (1st line
8254 # is EXPORTS), use it as is; otherwise, prepend...
8255 archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
8256 cp $export_symbols $output_objdir/$soname.def;
8257 else
8258 echo EXPORTS > $output_objdir/$soname.def;
8259 cat $export_symbols >> $output_objdir/$soname.def;
8261 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
8262 else
8263 ld_shlibs=no
8267 interix[3-9]*)
8268 hardcode_direct=no
8269 hardcode_shlibpath_var=no
8270 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
8271 export_dynamic_flag_spec='${wl}-E'
8272 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
8273 # Instead, shared libraries are loaded at an image base (0x10000000 by
8274 # default) and relocated if they conflict, which is a slow very memory
8275 # consuming and fragmenting process. To avoid this, we pick a random,
8276 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
8277 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
8278 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
8279 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'
8282 gnu* | linux* | tpf* | k*bsd*-gnu)
8283 tmp_diet=no
8284 if test "$host_os" = linux-dietlibc; then
8285 case $cc_basename in
8286 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
8287 esac
8289 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
8290 && test "$tmp_diet" = no
8291 then
8292 tmp_addflag=
8293 tmp_sharedflag='-shared'
8294 case $cc_basename,$host_cpu in
8295 pgcc*) # Portland Group C compiler
8296 whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
8297 tmp_addflag=' $pic_flag'
8299 pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers
8300 whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
8301 tmp_addflag=' $pic_flag -Mnomain' ;;
8302 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
8303 tmp_addflag=' -i_dynamic' ;;
8304 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
8305 tmp_addflag=' -i_dynamic -nofor_main' ;;
8306 ifc* | ifort*) # Intel Fortran compiler
8307 tmp_addflag=' -nofor_main' ;;
8308 lf95*) # Lahey Fortran 8.1
8309 whole_archive_flag_spec=
8310 tmp_sharedflag='--shared' ;;
8311 xl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
8312 tmp_sharedflag='-qmkshrobj'
8313 tmp_addflag= ;;
8314 esac
8315 case `$CC -V 2>&1 | sed 5q` in
8316 *Sun\ C*) # Sun C 5.9
8317 whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive'
8318 compiler_needs_object=yes
8319 tmp_sharedflag='-G' ;;
8320 *Sun\ F*) # Sun Fortran 8.3
8321 tmp_sharedflag='-G' ;;
8322 esac
8323 archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8325 if test "x$supports_anon_versioning" = xyes; then
8326 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
8327 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
8328 echo "local: *; };" >> $output_objdir/$libname.ver~
8329 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
8332 case $cc_basename in
8333 xlf*)
8334 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
8335 whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
8336 hardcode_libdir_flag_spec=
8337 hardcode_libdir_flag_spec_ld='-rpath $libdir'
8338 archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
8339 if test "x$supports_anon_versioning" = xyes; then
8340 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
8341 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
8342 echo "local: *; };" >> $output_objdir/$libname.ver~
8343 $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
8346 esac
8347 else
8348 ld_shlibs=no
8352 netbsd*)
8353 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
8354 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
8355 wlarc=
8356 else
8357 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8358 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8362 solaris*)
8363 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
8364 ld_shlibs=no
8365 cat <<_LT_EOF 1>&2
8367 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
8368 *** create shared libraries on Solaris systems. Therefore, libtool
8369 *** is disabling shared libraries support. We urge you to upgrade GNU
8370 *** binutils to release 2.9.1 or newer. Another option is to modify
8371 *** your PATH or compiler configuration so that the native linker is
8372 *** used, and then restart.
8374 _LT_EOF
8375 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
8376 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8377 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8378 else
8379 ld_shlibs=no
8383 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
8384 case `$LD -v 2>&1` in
8385 *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
8386 ld_shlibs=no
8387 cat <<_LT_EOF 1>&2
8389 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
8390 *** reliably create shared libraries on SCO systems. Therefore, libtool
8391 *** is disabling shared libraries support. We urge you to upgrade GNU
8392 *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
8393 *** your PATH or compiler configuration so that the native linker is
8394 *** used, and then restart.
8396 _LT_EOF
8399 # For security reasons, it is highly recommended that you always
8400 # use absolute paths for naming shared libraries, and exclude the
8401 # DT_RUNPATH tag from executables and libraries. But doing so
8402 # requires that you compile everything twice, which is a pain.
8403 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
8404 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8405 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8406 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8407 else
8408 ld_shlibs=no
8411 esac
8414 sunos4*)
8415 archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8416 wlarc=
8417 hardcode_direct=yes
8418 hardcode_shlibpath_var=no
8422 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
8423 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8424 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8425 else
8426 ld_shlibs=no
8429 esac
8431 if test "$ld_shlibs" = no; then
8432 runpath_var=
8433 hardcode_libdir_flag_spec=
8434 export_dynamic_flag_spec=
8435 whole_archive_flag_spec=
8437 else
8438 # PORTME fill in a description of your system's linker (not GNU ld)
8439 case $host_os in
8440 aix3*)
8441 allow_undefined_flag=unsupported
8442 always_export_symbols=yes
8443 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'
8444 # Note: this linker hardcodes the directories in LIBPATH if there
8445 # are no directories specified by -L.
8446 hardcode_minus_L=yes
8447 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
8448 # Neither direct hardcoding nor static linking is supported with a
8449 # broken collect2.
8450 hardcode_direct=unsupported
8454 aix[4-9]*)
8455 if test "$host_cpu" = ia64; then
8456 # On IA64, the linker does run time linking by default, so we don't
8457 # have to do anything special.
8458 aix_use_runtimelinking=no
8459 exp_sym_flag='-Bexport'
8460 no_entry_flag=""
8461 else
8462 # If we're using GNU nm, then we don't want the "-C" option.
8463 # -C means demangle to AIX nm, but means don't demangle with GNU nm
8464 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
8465 export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
8466 else
8467 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'
8469 aix_use_runtimelinking=no
8471 # Test if we are trying to use run time linking or normal
8472 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
8473 # need to do runtime linking.
8474 case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
8475 for ld_flag in $LDFLAGS; do
8476 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
8477 aix_use_runtimelinking=yes
8478 break
8480 done
8482 esac
8484 exp_sym_flag='-bexport'
8485 no_entry_flag='-bnoentry'
8488 # When large executables or shared objects are built, AIX ld can
8489 # have problems creating the table of contents. If linking a library
8490 # or program results in "error TOC overflow" add -mminimal-toc to
8491 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
8492 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
8494 archive_cmds=''
8495 hardcode_direct=yes
8496 hardcode_direct_absolute=yes
8497 hardcode_libdir_separator=':'
8498 link_all_deplibs=yes
8499 file_list_spec='${wl}-f,'
8501 if test "$GCC" = yes; then
8502 case $host_os in aix4.[012]|aix4.[012].*)
8503 # We only want to do this on AIX 4.2 and lower, the check
8504 # below for broken collect2 doesn't work under 4.3+
8505 collect2name=`${CC} -print-prog-name=collect2`
8506 if test -f "$collect2name" &&
8507 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
8508 then
8509 # We have reworked collect2
8511 else
8512 # We have old collect2
8513 hardcode_direct=unsupported
8514 # It fails to find uninstalled libraries when the uninstalled
8515 # path is not listed in the libpath. Setting hardcode_minus_L
8516 # to unsupported forces relinking
8517 hardcode_minus_L=yes
8518 hardcode_libdir_flag_spec='-L$libdir'
8519 hardcode_libdir_separator=
8522 esac
8523 shared_flag='-shared'
8524 if test "$aix_use_runtimelinking" = yes; then
8525 shared_flag="$shared_flag "'${wl}-G'
8527 else
8528 # not using gcc
8529 if test "$host_cpu" = ia64; then
8530 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
8531 # chokes on -Wl,-G. The following line is correct:
8532 shared_flag='-G'
8533 else
8534 if test "$aix_use_runtimelinking" = yes; then
8535 shared_flag='${wl}-G'
8536 else
8537 shared_flag='${wl}-bM:SRE'
8542 export_dynamic_flag_spec='${wl}-bexpall'
8543 # It seems that -bexpall does not export symbols beginning with
8544 # underscore (_), so it is better to generate a list of symbols to export.
8545 always_export_symbols=yes
8546 if test "$aix_use_runtimelinking" = yes; then
8547 # Warning - without using the other runtime loading flags (-brtl),
8548 # -berok will link without error, but may produce a broken library.
8549 allow_undefined_flag='-berok'
8550 # Determine the default libpath from the value encoded in an
8551 # empty executable.
8552 cat >conftest.$ac_ext <<_ACEOF
8553 /* confdefs.h. */
8554 _ACEOF
8555 cat confdefs.h >>conftest.$ac_ext
8556 cat >>conftest.$ac_ext <<_ACEOF
8557 /* end confdefs.h. */
8560 main ()
8564 return 0;
8566 _ACEOF
8567 rm -f conftest.$ac_objext conftest$ac_exeext
8568 if { (ac_try="$ac_link"
8569 case "(($ac_try" in
8570 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8571 *) ac_try_echo=$ac_try;;
8572 esac
8573 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8574 $as_echo "$ac_try_echo") >&5
8575 (eval "$ac_link") 2>conftest.er1
8576 ac_status=$?
8577 grep -v '^ *+' conftest.er1 >conftest.err
8578 rm -f conftest.er1
8579 cat conftest.err >&5
8580 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8581 (exit $ac_status); } && {
8582 test -z "$ac_c_werror_flag" ||
8583 test ! -s conftest.err
8584 } && test -s conftest$ac_exeext && {
8585 test "$cross_compiling" = yes ||
8586 $as_test_x conftest$ac_exeext
8587 }; then
8589 lt_aix_libpath_sed='
8590 /Import File Strings/,/^$/ {
8591 /^0/ {
8592 s/^0 *\(.*\)$/\1/
8596 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
8597 # Check for a 64-bit object if we didn't find anything.
8598 if test -z "$aix_libpath"; then
8599 aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
8601 else
8602 $as_echo "$as_me: failed program was:" >&5
8603 sed 's/^/| /' conftest.$ac_ext >&5
8608 rm -rf conftest.dSYM
8609 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8610 conftest$ac_exeext conftest.$ac_ext
8611 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
8613 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
8614 archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
8615 else
8616 if test "$host_cpu" = ia64; then
8617 hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
8618 allow_undefined_flag="-z nodefs"
8619 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"
8620 else
8621 # Determine the default libpath from the value encoded in an
8622 # empty executable.
8623 cat >conftest.$ac_ext <<_ACEOF
8624 /* confdefs.h. */
8625 _ACEOF
8626 cat confdefs.h >>conftest.$ac_ext
8627 cat >>conftest.$ac_ext <<_ACEOF
8628 /* end confdefs.h. */
8631 main ()
8635 return 0;
8637 _ACEOF
8638 rm -f conftest.$ac_objext conftest$ac_exeext
8639 if { (ac_try="$ac_link"
8640 case "(($ac_try" in
8641 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8642 *) ac_try_echo=$ac_try;;
8643 esac
8644 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8645 $as_echo "$ac_try_echo") >&5
8646 (eval "$ac_link") 2>conftest.er1
8647 ac_status=$?
8648 grep -v '^ *+' conftest.er1 >conftest.err
8649 rm -f conftest.er1
8650 cat conftest.err >&5
8651 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8652 (exit $ac_status); } && {
8653 test -z "$ac_c_werror_flag" ||
8654 test ! -s conftest.err
8655 } && test -s conftest$ac_exeext && {
8656 test "$cross_compiling" = yes ||
8657 $as_test_x conftest$ac_exeext
8658 }; then
8660 lt_aix_libpath_sed='
8661 /Import File Strings/,/^$/ {
8662 /^0/ {
8663 s/^0 *\(.*\)$/\1/
8667 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
8668 # Check for a 64-bit object if we didn't find anything.
8669 if test -z "$aix_libpath"; then
8670 aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
8672 else
8673 $as_echo "$as_me: failed program was:" >&5
8674 sed 's/^/| /' conftest.$ac_ext >&5
8679 rm -rf conftest.dSYM
8680 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8681 conftest$ac_exeext conftest.$ac_ext
8682 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
8684 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
8685 # Warning - without using the other run time loading flags,
8686 # -berok will link without error, but may produce a broken library.
8687 no_undefined_flag=' ${wl}-bernotok'
8688 allow_undefined_flag=' ${wl}-berok'
8689 # Exported symbols can be pulled into shared objects from archives
8690 whole_archive_flag_spec='$convenience'
8691 archive_cmds_need_lc=yes
8692 # This is similar to how AIX traditionally builds its shared libraries.
8693 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'
8698 amigaos*)
8699 case $host_cpu in
8700 powerpc)
8701 # see comment about AmigaOS4 .so support
8702 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8703 archive_expsym_cmds=''
8705 m68k)
8706 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)'
8707 hardcode_libdir_flag_spec='-L$libdir'
8708 hardcode_minus_L=yes
8710 esac
8713 bsdi[45]*)
8714 export_dynamic_flag_spec=-rdynamic
8717 cygwin* | mingw* | pw32* | cegcc*)
8718 # When not using gcc, we currently assume that we are using
8719 # Microsoft Visual C++.
8720 # hardcode_libdir_flag_spec is actually meaningless, as there is
8721 # no search path for DLLs.
8722 hardcode_libdir_flag_spec=' '
8723 allow_undefined_flag=unsupported
8724 # Tell ltmain to make .lib files, not .a files.
8725 libext=lib
8726 # Tell ltmain to make .dll files, not .so files.
8727 shrext_cmds=".dll"
8728 # FIXME: Setting linknames here is a bad hack.
8729 archive_cmds='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames='
8730 # The linker will automatically build a .lib file if we build a DLL.
8731 old_archive_from_new_cmds='true'
8732 # FIXME: Should let the user specify the lib program.
8733 old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
8734 fix_srcfile_path='`cygpath -w "$srcfile"`'
8735 enable_shared_with_static_runtimes=yes
8738 darwin* | rhapsody*)
8741 archive_cmds_need_lc=no
8742 hardcode_direct=no
8743 hardcode_automatic=yes
8744 hardcode_shlibpath_var=unsupported
8745 whole_archive_flag_spec=''
8746 link_all_deplibs=yes
8747 allow_undefined_flag="$_lt_dar_allow_undefined"
8748 case $cc_basename in
8749 ifort*) _lt_dar_can_shared=yes ;;
8750 *) _lt_dar_can_shared=$GCC ;;
8751 esac
8752 if test "$_lt_dar_can_shared" = "yes"; then
8753 output_verbose_link_cmd=echo
8754 archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
8755 module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
8756 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}"
8757 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}"
8759 else
8760 ld_shlibs=no
8765 dgux*)
8766 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8767 hardcode_libdir_flag_spec='-L$libdir'
8768 hardcode_shlibpath_var=no
8771 freebsd1*)
8772 ld_shlibs=no
8775 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
8776 # support. Future versions do this automatically, but an explicit c++rt0.o
8777 # does not break anything, and helps significantly (at the cost of a little
8778 # extra space).
8779 freebsd2.2*)
8780 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
8781 hardcode_libdir_flag_spec='-R$libdir'
8782 hardcode_direct=yes
8783 hardcode_shlibpath_var=no
8786 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
8787 freebsd2*)
8788 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8789 hardcode_direct=yes
8790 hardcode_minus_L=yes
8791 hardcode_shlibpath_var=no
8794 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
8795 freebsd* | dragonfly*)
8796 archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
8797 hardcode_libdir_flag_spec='-R$libdir'
8798 hardcode_direct=yes
8799 hardcode_shlibpath_var=no
8802 hpux9*)
8803 if test "$GCC" = yes; then
8804 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'
8805 else
8806 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'
8808 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8809 hardcode_libdir_separator=:
8810 hardcode_direct=yes
8812 # hardcode_minus_L: Not really in the search PATH,
8813 # but as the default location of the library.
8814 hardcode_minus_L=yes
8815 export_dynamic_flag_spec='${wl}-E'
8818 hpux10*)
8819 if test "$GCC" = yes -a "$with_gnu_ld" = no; then
8820 archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
8821 else
8822 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
8824 if test "$with_gnu_ld" = no; then
8825 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8826 hardcode_libdir_flag_spec_ld='+b $libdir'
8827 hardcode_libdir_separator=:
8828 hardcode_direct=yes
8829 hardcode_direct_absolute=yes
8830 export_dynamic_flag_spec='${wl}-E'
8831 # hardcode_minus_L: Not really in the search PATH,
8832 # but as the default location of the library.
8833 hardcode_minus_L=yes
8837 hpux11*)
8838 if test "$GCC" = yes -a "$with_gnu_ld" = no; then
8839 case $host_cpu in
8840 hppa*64*)
8841 archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8843 ia64*)
8844 archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
8847 archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
8849 esac
8850 else
8851 case $host_cpu in
8852 hppa*64*)
8853 archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8855 ia64*)
8856 archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
8859 archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
8861 esac
8863 if test "$with_gnu_ld" = no; then
8864 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8865 hardcode_libdir_separator=:
8867 case $host_cpu in
8868 hppa*64*|ia64*)
8869 hardcode_direct=no
8870 hardcode_shlibpath_var=no
8873 hardcode_direct=yes
8874 hardcode_direct_absolute=yes
8875 export_dynamic_flag_spec='${wl}-E'
8877 # hardcode_minus_L: Not really in the search PATH,
8878 # but as the default location of the library.
8879 hardcode_minus_L=yes
8881 esac
8885 irix5* | irix6* | nonstopux*)
8886 if test "$GCC" = yes; then
8887 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
8888 # Try to use the -exported_symbol ld option, if it does not
8889 # work, assume that -exports_file does not work either and
8890 # implicitly export all symbols.
8891 save_LDFLAGS="$LDFLAGS"
8892 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
8893 cat >conftest.$ac_ext <<_ACEOF
8894 int foo(void) {}
8895 _ACEOF
8896 rm -f conftest.$ac_objext conftest$ac_exeext
8897 if { (ac_try="$ac_link"
8898 case "(($ac_try" in
8899 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8900 *) ac_try_echo=$ac_try;;
8901 esac
8902 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8903 $as_echo "$ac_try_echo") >&5
8904 (eval "$ac_link") 2>conftest.er1
8905 ac_status=$?
8906 grep -v '^ *+' conftest.er1 >conftest.err
8907 rm -f conftest.er1
8908 cat conftest.err >&5
8909 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8910 (exit $ac_status); } && {
8911 test -z "$ac_c_werror_flag" ||
8912 test ! -s conftest.err
8913 } && test -s conftest$ac_exeext && {
8914 test "$cross_compiling" = yes ||
8915 $as_test_x conftest$ac_exeext
8916 }; then
8917 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
8919 else
8920 $as_echo "$as_me: failed program was:" >&5
8921 sed 's/^/| /' conftest.$ac_ext >&5
8926 rm -rf conftest.dSYM
8927 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8928 conftest$ac_exeext conftest.$ac_ext
8929 LDFLAGS="$save_LDFLAGS"
8930 else
8931 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
8932 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
8934 archive_cmds_need_lc='no'
8935 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8936 hardcode_libdir_separator=:
8937 inherit_rpath=yes
8938 link_all_deplibs=yes
8941 netbsd*)
8942 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
8943 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
8944 else
8945 archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
8947 hardcode_libdir_flag_spec='-R$libdir'
8948 hardcode_direct=yes
8949 hardcode_shlibpath_var=no
8952 newsos6)
8953 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8954 hardcode_direct=yes
8955 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8956 hardcode_libdir_separator=:
8957 hardcode_shlibpath_var=no
8960 *nto* | *qnx*)
8963 openbsd*)
8964 if test -f /usr/libexec/ld.so; then
8965 hardcode_direct=yes
8966 hardcode_shlibpath_var=no
8967 hardcode_direct_absolute=yes
8968 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
8969 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
8970 archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
8971 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
8972 export_dynamic_flag_spec='${wl}-E'
8973 else
8974 case $host_os in
8975 openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
8976 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8977 hardcode_libdir_flag_spec='-R$libdir'
8980 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
8981 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
8983 esac
8985 else
8986 ld_shlibs=no
8990 os2*)
8991 hardcode_libdir_flag_spec='-L$libdir'
8992 hardcode_minus_L=yes
8993 allow_undefined_flag=unsupported
8994 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'
8995 old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
8998 osf3*)
8999 if test "$GCC" = yes; then
9000 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
9001 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
9002 else
9003 allow_undefined_flag=' -expect_unresolved \*'
9004 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
9006 archive_cmds_need_lc='no'
9007 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
9008 hardcode_libdir_separator=:
9011 osf4* | osf5*) # as osf3* with the addition of -msym flag
9012 if test "$GCC" = yes; then
9013 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
9014 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
9015 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
9016 else
9017 allow_undefined_flag=' -expect_unresolved \*'
9018 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
9019 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~
9020 $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
9022 # Both c and cxx compiler support -rpath directly
9023 hardcode_libdir_flag_spec='-rpath $libdir'
9025 archive_cmds_need_lc='no'
9026 hardcode_libdir_separator=:
9029 solaris*)
9030 no_undefined_flag=' -z defs'
9031 if test "$GCC" = yes; then
9032 wlarc='${wl}'
9033 archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
9034 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
9035 $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
9036 else
9037 case `$CC -V 2>&1` in
9038 *"Compilers 5.0"*)
9039 wlarc=''
9040 archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
9041 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
9042 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
9045 wlarc='${wl}'
9046 archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
9047 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
9048 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
9050 esac
9052 hardcode_libdir_flag_spec='-R$libdir'
9053 hardcode_shlibpath_var=no
9054 case $host_os in
9055 solaris2.[0-5] | solaris2.[0-5].*) ;;
9057 # The compiler driver will combine and reorder linker options,
9058 # but understands `-z linker_flag'. GCC discards it without `$wl',
9059 # but is careful enough not to reorder.
9060 # Supported since Solaris 2.6 (maybe 2.5.1?)
9061 if test "$GCC" = yes; then
9062 whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
9063 else
9064 whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
9067 esac
9068 link_all_deplibs=yes
9071 sunos4*)
9072 if test "x$host_vendor" = xsequent; then
9073 # Use $CC to link under sequent, because it throws in some extra .o
9074 # files that make .init and .fini sections work.
9075 archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
9076 else
9077 archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
9079 hardcode_libdir_flag_spec='-L$libdir'
9080 hardcode_direct=yes
9081 hardcode_minus_L=yes
9082 hardcode_shlibpath_var=no
9085 sysv4)
9086 case $host_vendor in
9087 sni)
9088 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9089 hardcode_direct=yes # is this really true???
9091 siemens)
9092 ## LD is ld it makes a PLAMLIB
9093 ## CC just makes a GrossModule.
9094 archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
9095 reload_cmds='$CC -r -o $output$reload_objs'
9096 hardcode_direct=no
9098 motorola)
9099 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9100 hardcode_direct=no #Motorola manual says yes, but my tests say they lie
9102 esac
9103 runpath_var='LD_RUN_PATH'
9104 hardcode_shlibpath_var=no
9107 sysv4.3*)
9108 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9109 hardcode_shlibpath_var=no
9110 export_dynamic_flag_spec='-Bexport'
9113 sysv4*MP*)
9114 if test -d /usr/nec; then
9115 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9116 hardcode_shlibpath_var=no
9117 runpath_var=LD_RUN_PATH
9118 hardcode_runpath_var=yes
9119 ld_shlibs=yes
9123 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
9124 no_undefined_flag='${wl}-z,text'
9125 archive_cmds_need_lc=no
9126 hardcode_shlibpath_var=no
9127 runpath_var='LD_RUN_PATH'
9129 if test "$GCC" = yes; then
9130 archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9131 archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9132 else
9133 archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9134 archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9138 sysv5* | sco3.2v5* | sco5v6*)
9139 # Note: We can NOT use -z defs as we might desire, because we do not
9140 # link with -lc, and that would cause any symbols used from libc to
9141 # always be unresolved, which means just about no library would
9142 # ever link correctly. If we're not using GNU ld we use -z text
9143 # though, which does catch some bad symbols but isn't as heavy-handed
9144 # as -z defs.
9145 no_undefined_flag='${wl}-z,text'
9146 allow_undefined_flag='${wl}-z,nodefs'
9147 archive_cmds_need_lc=no
9148 hardcode_shlibpath_var=no
9149 hardcode_libdir_flag_spec='${wl}-R,$libdir'
9150 hardcode_libdir_separator=':'
9151 link_all_deplibs=yes
9152 export_dynamic_flag_spec='${wl}-Bexport'
9153 runpath_var='LD_RUN_PATH'
9155 if test "$GCC" = yes; then
9156 archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9157 archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9158 else
9159 archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9160 archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9164 uts4*)
9165 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9166 hardcode_libdir_flag_spec='-L$libdir'
9167 hardcode_shlibpath_var=no
9171 ld_shlibs=no
9173 esac
9175 if test x$host_vendor = xsni; then
9176 case $host in
9177 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
9178 export_dynamic_flag_spec='${wl}-Blargedynsym'
9180 esac
9184 { $as_echo "$as_me:$LINENO: result: $ld_shlibs" >&5
9185 $as_echo "$ld_shlibs" >&6; }
9186 test "$ld_shlibs" = no && can_build_shared=no
9188 with_gnu_ld=$with_gnu_ld
9205 # Do we need to explicitly link libc?
9207 case "x$archive_cmds_need_lc" in
9208 x|xyes)
9209 # Assume -lc should be added
9210 archive_cmds_need_lc=yes
9212 if test "$enable_shared" = yes && test "$GCC" = yes; then
9213 case $archive_cmds in
9214 *'~'*)
9215 # FIXME: we may have to deal with multi-command sequences.
9217 '$CC '*)
9218 # Test whether the compiler implicitly links with -lc since on some
9219 # systems, -lgcc has to come before -lc. If gcc already passes -lc
9220 # to ld, don't add -lc before -lgcc.
9221 { $as_echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
9222 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
9223 $RM conftest*
9224 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
9226 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9227 (eval $ac_compile) 2>&5
9228 ac_status=$?
9229 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9230 (exit $ac_status); } 2>conftest.err; then
9231 soname=conftest
9232 lib=conftest
9233 libobjs=conftest.$ac_objext
9234 deplibs=
9235 wl=$lt_prog_compiler_wl
9236 pic_flag=$lt_prog_compiler_pic
9237 compiler_flags=-v
9238 linker_flags=-v
9239 verstring=
9240 output_objdir=.
9241 libname=conftest
9242 lt_save_allow_undefined_flag=$allow_undefined_flag
9243 allow_undefined_flag=
9244 if { (eval echo "$as_me:$LINENO: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\"") >&5
9245 (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
9246 ac_status=$?
9247 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9248 (exit $ac_status); }
9249 then
9250 archive_cmds_need_lc=no
9251 else
9252 archive_cmds_need_lc=yes
9254 allow_undefined_flag=$lt_save_allow_undefined_flag
9255 else
9256 cat conftest.err 1>&5
9258 $RM conftest*
9259 { $as_echo "$as_me:$LINENO: result: $archive_cmds_need_lc" >&5
9260 $as_echo "$archive_cmds_need_lc" >&6; }
9262 esac
9265 esac
9423 { $as_echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
9424 $as_echo_n "checking dynamic linker characteristics... " >&6; }
9426 if test "$GCC" = yes; then
9427 case $host_os in
9428 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
9429 *) lt_awk_arg="/^libraries:/" ;;
9430 esac
9431 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
9432 if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then
9433 # if the path contains ";" then we assume it to be the separator
9434 # otherwise default to the standard path separator (i.e. ":") - it is
9435 # assumed that no part of a normal pathname contains ";" but that should
9436 # okay in the real world where ";" in dirpaths is itself problematic.
9437 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'`
9438 else
9439 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
9441 # Ok, now we have the path, separated by spaces, we can step through it
9442 # and add multilib dir if necessary.
9443 lt_tmp_lt_search_path_spec=
9444 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
9445 for lt_sys_path in $lt_search_path_spec; do
9446 if test -d "$lt_sys_path/$lt_multi_os_dir"; then
9447 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
9448 else
9449 test -d "$lt_sys_path" && \
9450 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
9452 done
9453 lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk '
9454 BEGIN {RS=" "; FS="/|\n";} {
9455 lt_foo="";
9456 lt_count=0;
9457 for (lt_i = NF; lt_i > 0; lt_i--) {
9458 if ($lt_i != "" && $lt_i != ".") {
9459 if ($lt_i == "..") {
9460 lt_count++;
9461 } else {
9462 if (lt_count == 0) {
9463 lt_foo="/" $lt_i lt_foo;
9464 } else {
9465 lt_count--;
9470 if (lt_foo != "") { lt_freq[lt_foo]++; }
9471 if (lt_freq[lt_foo] == 1) { print lt_foo; }
9473 sys_lib_search_path_spec=`$ECHO $lt_search_path_spec`
9474 else
9475 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
9477 library_names_spec=
9478 libname_spec='lib$name'
9479 soname_spec=
9480 shrext_cmds=".so"
9481 postinstall_cmds=
9482 postuninstall_cmds=
9483 finish_cmds=
9484 finish_eval=
9485 shlibpath_var=
9486 shlibpath_overrides_runpath=unknown
9487 version_type=none
9488 dynamic_linker="$host_os ld.so"
9489 sys_lib_dlsearch_path_spec="/lib /usr/lib"
9490 need_lib_prefix=unknown
9491 hardcode_into_libs=no
9493 # when you set need_version to no, make sure it does not cause -set_version
9494 # flags to be left without arguments
9495 need_version=unknown
9497 case $host_os in
9498 aix3*)
9499 version_type=linux
9500 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
9501 shlibpath_var=LIBPATH
9503 # AIX 3 has no versioning support, so we append a major version to the name.
9504 soname_spec='${libname}${release}${shared_ext}$major'
9507 aix[4-9]*)
9508 version_type=linux
9509 need_lib_prefix=no
9510 need_version=no
9511 hardcode_into_libs=yes
9512 if test "$host_cpu" = ia64; then
9513 # AIX 5 supports IA64
9514 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
9515 shlibpath_var=LD_LIBRARY_PATH
9516 else
9517 # With GCC up to 2.95.x, collect2 would create an import file
9518 # for dependence libraries. The import file would start with
9519 # the line `#! .'. This would cause the generated library to
9520 # depend on `.', always an invalid library. This was fixed in
9521 # development snapshots of GCC prior to 3.0.
9522 case $host_os in
9523 aix4 | aix4.[01] | aix4.[01].*)
9524 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
9525 echo ' yes '
9526 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
9528 else
9529 can_build_shared=no
9532 esac
9533 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
9534 # soname into executable. Probably we can add versioning support to
9535 # collect2, so additional links can be useful in future.
9536 if test "$aix_use_runtimelinking" = yes; then
9537 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
9538 # instead of lib<name>.a to let people know that these are not
9539 # typical AIX shared libraries.
9540 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9541 else
9542 # We preserve .a as extension for shared libraries through AIX4.2
9543 # and later when we are not doing run time linking.
9544 library_names_spec='${libname}${release}.a $libname.a'
9545 soname_spec='${libname}${release}${shared_ext}$major'
9547 shlibpath_var=LIBPATH
9551 amigaos*)
9552 case $host_cpu in
9553 powerpc)
9554 # Since July 2007 AmigaOS4 officially supports .so libraries.
9555 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
9556 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9558 m68k)
9559 library_names_spec='$libname.ixlibrary $libname.a'
9560 # Create ${libname}_ixlibrary.a entries in /sys/libs.
9561 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$ECHO "X$lib" | $Xsed -e '\''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'
9563 esac
9566 beos*)
9567 library_names_spec='${libname}${shared_ext}'
9568 dynamic_linker="$host_os ld.so"
9569 shlibpath_var=LIBRARY_PATH
9572 bsdi[45]*)
9573 version_type=linux
9574 need_version=no
9575 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9576 soname_spec='${libname}${release}${shared_ext}$major'
9577 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
9578 shlibpath_var=LD_LIBRARY_PATH
9579 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
9580 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
9581 # the default ld.so.conf also contains /usr/contrib/lib and
9582 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
9583 # libtool to hard-code these into programs
9586 cygwin* | mingw* | pw32* | cegcc*)
9587 version_type=windows
9588 shrext_cmds=".dll"
9589 need_version=no
9590 need_lib_prefix=no
9592 case $GCC,$host_os in
9593 yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
9594 library_names_spec='$libname.dll.a'
9595 # DLL is installed to $(libdir)/../bin by postinstall_cmds
9596 postinstall_cmds='base_file=`basename \${file}`~
9597 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
9598 dldir=$destdir/`dirname \$dlpath`~
9599 test -d \$dldir || mkdir -p \$dldir~
9600 $install_prog $dir/$dlname \$dldir/$dlname~
9601 chmod a+x \$dldir/$dlname~
9602 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
9603 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
9605 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
9606 dlpath=$dir/\$dldll~
9607 $RM \$dlpath'
9608 shlibpath_overrides_runpath=yes
9610 case $host_os in
9611 cygwin*)
9612 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
9613 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9614 sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
9616 mingw* | cegcc*)
9617 # MinGW DLLs use traditional 'lib' prefix
9618 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9619 sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
9620 if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
9621 # It is most probably a Windows format PATH printed by
9622 # mingw gcc, but we are running on Cygwin. Gcc prints its search
9623 # path with ; separators, and with drive letters. We can handle the
9624 # drive letters (cygwin fileutils understands them), so leave them,
9625 # especially as we might pass files found there to a mingw objdump,
9626 # which wouldn't understand a cygwinified path. Ahh.
9627 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
9628 else
9629 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
9632 pw32*)
9633 # pw32 DLLs use 'pw' prefix rather than 'lib'
9634 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9636 esac
9640 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
9642 esac
9643 dynamic_linker='Win32 ld.exe'
9644 # FIXME: first we should search . and the directory the executable is in
9645 shlibpath_var=PATH
9648 darwin* | rhapsody*)
9649 dynamic_linker="$host_os dyld"
9650 version_type=darwin
9651 need_lib_prefix=no
9652 need_version=no
9653 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
9654 soname_spec='${libname}${release}${major}$shared_ext'
9655 shlibpath_overrides_runpath=yes
9656 shlibpath_var=DYLD_LIBRARY_PATH
9657 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
9659 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
9660 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
9663 dgux*)
9664 version_type=linux
9665 need_lib_prefix=no
9666 need_version=no
9667 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
9668 soname_spec='${libname}${release}${shared_ext}$major'
9669 shlibpath_var=LD_LIBRARY_PATH
9672 freebsd1*)
9673 dynamic_linker=no
9676 freebsd* | dragonfly*)
9677 # DragonFly does not have aout. When/if they implement a new
9678 # versioning mechanism, adjust this.
9679 if test -x /usr/bin/objformat; then
9680 objformat=`/usr/bin/objformat`
9681 else
9682 case $host_os in
9683 freebsd[123]*) objformat=aout ;;
9684 *) objformat=elf ;;
9685 esac
9687 version_type=freebsd-$objformat
9688 case $version_type in
9689 freebsd-elf*)
9690 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
9691 need_version=no
9692 need_lib_prefix=no
9694 freebsd-*)
9695 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
9696 need_version=yes
9698 esac
9699 shlibpath_var=LD_LIBRARY_PATH
9700 case $host_os in
9701 freebsd2*)
9702 shlibpath_overrides_runpath=yes
9704 freebsd3.[01]* | freebsdelf3.[01]*)
9705 shlibpath_overrides_runpath=yes
9706 hardcode_into_libs=yes
9708 freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
9709 freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
9710 shlibpath_overrides_runpath=no
9711 hardcode_into_libs=yes
9713 *) # from 4.6 on, and DragonFly
9714 shlibpath_overrides_runpath=yes
9715 hardcode_into_libs=yes
9717 esac
9720 gnu*)
9721 version_type=linux
9722 need_lib_prefix=no
9723 need_version=no
9724 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
9725 soname_spec='${libname}${release}${shared_ext}$major'
9726 shlibpath_var=LD_LIBRARY_PATH
9727 hardcode_into_libs=yes
9730 hpux9* | hpux10* | hpux11*)
9731 # Give a soname corresponding to the major version so that dld.sl refuses to
9732 # link against other versions.
9733 version_type=sunos
9734 need_lib_prefix=no
9735 need_version=no
9736 case $host_cpu in
9737 ia64*)
9738 shrext_cmds='.so'
9739 hardcode_into_libs=yes
9740 dynamic_linker="$host_os dld.so"
9741 shlibpath_var=LD_LIBRARY_PATH
9742 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
9743 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9744 soname_spec='${libname}${release}${shared_ext}$major'
9745 if test "X$HPUX_IA64_MODE" = X32; then
9746 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
9747 else
9748 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
9750 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
9752 hppa*64*)
9753 shrext_cmds='.sl'
9754 hardcode_into_libs=yes
9755 dynamic_linker="$host_os dld.sl"
9756 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
9757 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
9758 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9759 soname_spec='${libname}${release}${shared_ext}$major'
9760 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
9761 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
9764 shrext_cmds='.sl'
9765 dynamic_linker="$host_os dld.sl"
9766 shlibpath_var=SHLIB_PATH
9767 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
9768 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9769 soname_spec='${libname}${release}${shared_ext}$major'
9771 esac
9772 # HP-UX runs *really* slowly unless shared libraries are mode 555.
9773 postinstall_cmds='chmod 555 $lib'
9776 interix[3-9]*)
9777 version_type=linux
9778 need_lib_prefix=no
9779 need_version=no
9780 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
9781 soname_spec='${libname}${release}${shared_ext}$major'
9782 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
9783 shlibpath_var=LD_LIBRARY_PATH
9784 shlibpath_overrides_runpath=no
9785 hardcode_into_libs=yes
9788 irix5* | irix6* | nonstopux*)
9789 case $host_os in
9790 nonstopux*) version_type=nonstopux ;;
9792 if test "$lt_cv_prog_gnu_ld" = yes; then
9793 version_type=linux
9794 else
9795 version_type=irix
9796 fi ;;
9797 esac
9798 need_lib_prefix=no
9799 need_version=no
9800 soname_spec='${libname}${release}${shared_ext}$major'
9801 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
9802 case $host_os in
9803 irix5* | nonstopux*)
9804 libsuff= shlibsuff=
9807 case $LD in # libtool.m4 will add one of these switches to LD
9808 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
9809 libsuff= shlibsuff= libmagic=32-bit;;
9810 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
9811 libsuff=32 shlibsuff=N32 libmagic=N32;;
9812 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
9813 libsuff=64 shlibsuff=64 libmagic=64-bit;;
9814 *) libsuff= shlibsuff= libmagic=never-match;;
9815 esac
9817 esac
9818 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
9819 shlibpath_overrides_runpath=no
9820 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
9821 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
9822 hardcode_into_libs=yes
9825 # No shared lib support for Linux oldld, aout, or coff.
9826 linux*oldld* | linux*aout* | linux*coff*)
9827 dynamic_linker=no
9830 # This must be Linux ELF.
9831 linux* | k*bsd*-gnu)
9832 version_type=linux
9833 need_lib_prefix=no
9834 need_version=no
9835 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9836 soname_spec='${libname}${release}${shared_ext}$major'
9837 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
9838 shlibpath_var=LD_LIBRARY_PATH
9839 shlibpath_overrides_runpath=no
9840 # Some binutils ld are patched to set DT_RUNPATH
9841 save_LDFLAGS=$LDFLAGS
9842 save_libdir=$libdir
9843 eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
9844 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
9845 cat >conftest.$ac_ext <<_ACEOF
9846 /* confdefs.h. */
9847 _ACEOF
9848 cat confdefs.h >>conftest.$ac_ext
9849 cat >>conftest.$ac_ext <<_ACEOF
9850 /* end confdefs.h. */
9853 main ()
9857 return 0;
9859 _ACEOF
9860 rm -f conftest.$ac_objext conftest$ac_exeext
9861 if { (ac_try="$ac_link"
9862 case "(($ac_try" in
9863 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9864 *) ac_try_echo=$ac_try;;
9865 esac
9866 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9867 $as_echo "$ac_try_echo") >&5
9868 (eval "$ac_link") 2>conftest.er1
9869 ac_status=$?
9870 grep -v '^ *+' conftest.er1 >conftest.err
9871 rm -f conftest.er1
9872 cat conftest.err >&5
9873 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9874 (exit $ac_status); } && {
9875 test -z "$ac_c_werror_flag" ||
9876 test ! -s conftest.err
9877 } && test -s conftest$ac_exeext && {
9878 test "$cross_compiling" = yes ||
9879 $as_test_x conftest$ac_exeext
9880 }; then
9881 if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then
9882 shlibpath_overrides_runpath=yes
9885 else
9886 $as_echo "$as_me: failed program was:" >&5
9887 sed 's/^/| /' conftest.$ac_ext >&5
9892 rm -rf conftest.dSYM
9893 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9894 conftest$ac_exeext conftest.$ac_ext
9895 LDFLAGS=$save_LDFLAGS
9896 libdir=$save_libdir
9898 # This implies no fast_install, which is unacceptable.
9899 # Some rework will be needed to allow for fast_install
9900 # before this can be enabled.
9901 hardcode_into_libs=yes
9903 # Append ld.so.conf contents to the search path
9904 if test -f /etc/ld.so.conf; then
9905 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;/^$/d' | tr '\n' ' '`
9906 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
9909 # We used to test for /lib/ld.so.1 and disable shared libraries on
9910 # powerpc, because MkLinux only supported shared libraries with the
9911 # GNU dynamic linker. Since this was broken with cross compilers,
9912 # most powerpc-linux boxes support dynamic linking these days and
9913 # people can always --disable-shared, the test was removed, and we
9914 # assume the GNU/Linux dynamic linker is in use.
9915 dynamic_linker='GNU/Linux ld.so'
9918 netbsd*)
9919 version_type=sunos
9920 need_lib_prefix=no
9921 need_version=no
9922 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
9923 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
9924 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
9925 dynamic_linker='NetBSD (a.out) ld.so'
9926 else
9927 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
9928 soname_spec='${libname}${release}${shared_ext}$major'
9929 dynamic_linker='NetBSD ld.elf_so'
9931 shlibpath_var=LD_LIBRARY_PATH
9932 shlibpath_overrides_runpath=yes
9933 hardcode_into_libs=yes
9936 newsos6)
9937 version_type=linux
9938 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9939 shlibpath_var=LD_LIBRARY_PATH
9940 shlibpath_overrides_runpath=yes
9943 *nto* | *qnx*)
9944 version_type=qnx
9945 need_lib_prefix=no
9946 need_version=no
9947 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9948 soname_spec='${libname}${release}${shared_ext}$major'
9949 shlibpath_var=LD_LIBRARY_PATH
9950 shlibpath_overrides_runpath=no
9951 hardcode_into_libs=yes
9952 dynamic_linker='ldqnx.so'
9955 openbsd*)
9956 version_type=sunos
9957 sys_lib_dlsearch_path_spec="/usr/lib"
9958 need_lib_prefix=no
9959 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
9960 case $host_os in
9961 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
9962 *) need_version=no ;;
9963 esac
9964 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
9965 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
9966 shlibpath_var=LD_LIBRARY_PATH
9967 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
9968 case $host_os in
9969 openbsd2.[89] | openbsd2.[89].*)
9970 shlibpath_overrides_runpath=no
9973 shlibpath_overrides_runpath=yes
9975 esac
9976 else
9977 shlibpath_overrides_runpath=yes
9981 os2*)
9982 libname_spec='$name'
9983 shrext_cmds=".dll"
9984 need_lib_prefix=no
9985 library_names_spec='$libname${shared_ext} $libname.a'
9986 dynamic_linker='OS/2 ld.exe'
9987 shlibpath_var=LIBPATH
9990 osf3* | osf4* | osf5*)
9991 version_type=osf
9992 need_lib_prefix=no
9993 need_version=no
9994 soname_spec='${libname}${release}${shared_ext}$major'
9995 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9996 shlibpath_var=LD_LIBRARY_PATH
9997 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
9998 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
10001 rdos*)
10002 dynamic_linker=no
10005 solaris*)
10006 version_type=linux
10007 need_lib_prefix=no
10008 need_version=no
10009 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10010 soname_spec='${libname}${release}${shared_ext}$major'
10011 shlibpath_var=LD_LIBRARY_PATH
10012 shlibpath_overrides_runpath=yes
10013 hardcode_into_libs=yes
10014 # ldd complains unless libraries are executable
10015 postinstall_cmds='chmod +x $lib'
10018 sunos4*)
10019 version_type=sunos
10020 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
10021 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
10022 shlibpath_var=LD_LIBRARY_PATH
10023 shlibpath_overrides_runpath=yes
10024 if test "$with_gnu_ld" = yes; then
10025 need_lib_prefix=no
10027 need_version=yes
10030 sysv4 | sysv4.3*)
10031 version_type=linux
10032 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10033 soname_spec='${libname}${release}${shared_ext}$major'
10034 shlibpath_var=LD_LIBRARY_PATH
10035 case $host_vendor in
10036 sni)
10037 shlibpath_overrides_runpath=no
10038 need_lib_prefix=no
10039 runpath_var=LD_RUN_PATH
10041 siemens)
10042 need_lib_prefix=no
10044 motorola)
10045 need_lib_prefix=no
10046 need_version=no
10047 shlibpath_overrides_runpath=no
10048 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
10050 esac
10053 sysv4*MP*)
10054 if test -d /usr/nec ;then
10055 version_type=linux
10056 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
10057 soname_spec='$libname${shared_ext}.$major'
10058 shlibpath_var=LD_LIBRARY_PATH
10062 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
10063 version_type=freebsd-elf
10064 need_lib_prefix=no
10065 need_version=no
10066 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
10067 soname_spec='${libname}${release}${shared_ext}$major'
10068 shlibpath_var=LD_LIBRARY_PATH
10069 shlibpath_overrides_runpath=yes
10070 hardcode_into_libs=yes
10071 if test "$with_gnu_ld" = yes; then
10072 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
10073 else
10074 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
10075 case $host_os in
10076 sco3.2v5*)
10077 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
10079 esac
10081 sys_lib_dlsearch_path_spec='/usr/lib'
10084 tpf*)
10085 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
10086 version_type=linux
10087 need_lib_prefix=no
10088 need_version=no
10089 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10090 shlibpath_var=LD_LIBRARY_PATH
10091 shlibpath_overrides_runpath=no
10092 hardcode_into_libs=yes
10095 uts4*)
10096 version_type=linux
10097 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10098 soname_spec='${libname}${release}${shared_ext}$major'
10099 shlibpath_var=LD_LIBRARY_PATH
10103 dynamic_linker=no
10105 esac
10106 { $as_echo "$as_me:$LINENO: result: $dynamic_linker" >&5
10107 $as_echo "$dynamic_linker" >&6; }
10108 test "$dynamic_linker" = no && can_build_shared=no
10110 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
10111 if test "$GCC" = yes; then
10112 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
10115 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
10116 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
10118 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
10119 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
10208 { $as_echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
10209 $as_echo_n "checking how to hardcode library paths into programs... " >&6; }
10210 hardcode_action=
10211 if test -n "$hardcode_libdir_flag_spec" ||
10212 test -n "$runpath_var" ||
10213 test "X$hardcode_automatic" = "Xyes" ; then
10215 # We can hardcode non-existent directories.
10216 if test "$hardcode_direct" != no &&
10217 # If the only mechanism to avoid hardcoding is shlibpath_var, we
10218 # have to relink, otherwise we might link with an installed library
10219 # when we should be linking with a yet-to-be-installed one
10220 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
10221 test "$hardcode_minus_L" != no; then
10222 # Linking always hardcodes the temporary library directory.
10223 hardcode_action=relink
10224 else
10225 # We can link without hardcoding, and we can hardcode nonexisting dirs.
10226 hardcode_action=immediate
10228 else
10229 # We cannot hardcode anything, or else we can only hardcode existing
10230 # directories.
10231 hardcode_action=unsupported
10233 { $as_echo "$as_me:$LINENO: result: $hardcode_action" >&5
10234 $as_echo "$hardcode_action" >&6; }
10236 if test "$hardcode_action" = relink ||
10237 test "$inherit_rpath" = yes; then
10238 # Fast installation is not supported
10239 enable_fast_install=no
10240 elif test "$shlibpath_overrides_runpath" = yes ||
10241 test "$enable_shared" = no; then
10242 # Fast installation is not necessary
10243 enable_fast_install=needless
10251 if test "x$enable_dlopen" != xyes; then
10252 enable_dlopen=unknown
10253 enable_dlopen_self=unknown
10254 enable_dlopen_self_static=unknown
10255 else
10256 lt_cv_dlopen=no
10257 lt_cv_dlopen_libs=
10259 case $host_os in
10260 beos*)
10261 lt_cv_dlopen="load_add_on"
10262 lt_cv_dlopen_libs=
10263 lt_cv_dlopen_self=yes
10266 mingw* | pw32* | cegcc*)
10267 lt_cv_dlopen="LoadLibrary"
10268 lt_cv_dlopen_libs=
10271 cygwin*)
10272 lt_cv_dlopen="dlopen"
10273 lt_cv_dlopen_libs=
10276 darwin*)
10277 # if libdl is installed we need to link against it
10278 { $as_echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
10279 $as_echo_n "checking for dlopen in -ldl... " >&6; }
10280 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
10281 $as_echo_n "(cached) " >&6
10282 else
10283 ac_check_lib_save_LIBS=$LIBS
10284 LIBS="-ldl $LIBS"
10285 cat >conftest.$ac_ext <<_ACEOF
10286 /* confdefs.h. */
10287 _ACEOF
10288 cat confdefs.h >>conftest.$ac_ext
10289 cat >>conftest.$ac_ext <<_ACEOF
10290 /* end confdefs.h. */
10292 /* Override any GCC internal prototype to avoid an error.
10293 Use char because int might match the return type of a GCC
10294 builtin and then its argument prototype would still apply. */
10295 #ifdef __cplusplus
10296 extern "C"
10297 #endif
10298 char dlopen ();
10300 main ()
10302 return dlopen ();
10304 return 0;
10306 _ACEOF
10307 rm -f conftest.$ac_objext conftest$ac_exeext
10308 if { (ac_try="$ac_link"
10309 case "(($ac_try" in
10310 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10311 *) ac_try_echo=$ac_try;;
10312 esac
10313 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10314 $as_echo "$ac_try_echo") >&5
10315 (eval "$ac_link") 2>conftest.er1
10316 ac_status=$?
10317 grep -v '^ *+' conftest.er1 >conftest.err
10318 rm -f conftest.er1
10319 cat conftest.err >&5
10320 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10321 (exit $ac_status); } && {
10322 test -z "$ac_c_werror_flag" ||
10323 test ! -s conftest.err
10324 } && test -s conftest$ac_exeext && {
10325 test "$cross_compiling" = yes ||
10326 $as_test_x conftest$ac_exeext
10327 }; then
10328 ac_cv_lib_dl_dlopen=yes
10329 else
10330 $as_echo "$as_me: failed program was:" >&5
10331 sed 's/^/| /' conftest.$ac_ext >&5
10333 ac_cv_lib_dl_dlopen=no
10336 rm -rf conftest.dSYM
10337 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10338 conftest$ac_exeext conftest.$ac_ext
10339 LIBS=$ac_check_lib_save_LIBS
10341 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
10342 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
10343 if test "x$ac_cv_lib_dl_dlopen" = x""yes; then
10344 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
10345 else
10347 lt_cv_dlopen="dyld"
10348 lt_cv_dlopen_libs=
10349 lt_cv_dlopen_self=yes
10356 { $as_echo "$as_me:$LINENO: checking for shl_load" >&5
10357 $as_echo_n "checking for shl_load... " >&6; }
10358 if test "${ac_cv_func_shl_load+set}" = set; then
10359 $as_echo_n "(cached) " >&6
10360 else
10361 cat >conftest.$ac_ext <<_ACEOF
10362 /* confdefs.h. */
10363 _ACEOF
10364 cat confdefs.h >>conftest.$ac_ext
10365 cat >>conftest.$ac_ext <<_ACEOF
10366 /* end confdefs.h. */
10367 /* Define shl_load to an innocuous variant, in case <limits.h> declares shl_load.
10368 For example, HP-UX 11i <limits.h> declares gettimeofday. */
10369 #define shl_load innocuous_shl_load
10371 /* System header to define __stub macros and hopefully few prototypes,
10372 which can conflict with char shl_load (); below.
10373 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10374 <limits.h> exists even on freestanding compilers. */
10376 #ifdef __STDC__
10377 # include <limits.h>
10378 #else
10379 # include <assert.h>
10380 #endif
10382 #undef shl_load
10384 /* Override any GCC internal prototype to avoid an error.
10385 Use char because int might match the return type of a GCC
10386 builtin and then its argument prototype would still apply. */
10387 #ifdef __cplusplus
10388 extern "C"
10389 #endif
10390 char shl_load ();
10391 /* The GNU C library defines this for functions which it implements
10392 to always fail with ENOSYS. Some functions are actually named
10393 something starting with __ and the normal name is an alias. */
10394 #if defined __stub_shl_load || defined __stub___shl_load
10395 choke me
10396 #endif
10399 main ()
10401 return shl_load ();
10403 return 0;
10405 _ACEOF
10406 rm -f conftest.$ac_objext conftest$ac_exeext
10407 if { (ac_try="$ac_link"
10408 case "(($ac_try" in
10409 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10410 *) ac_try_echo=$ac_try;;
10411 esac
10412 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10413 $as_echo "$ac_try_echo") >&5
10414 (eval "$ac_link") 2>conftest.er1
10415 ac_status=$?
10416 grep -v '^ *+' conftest.er1 >conftest.err
10417 rm -f conftest.er1
10418 cat conftest.err >&5
10419 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10420 (exit $ac_status); } && {
10421 test -z "$ac_c_werror_flag" ||
10422 test ! -s conftest.err
10423 } && test -s conftest$ac_exeext && {
10424 test "$cross_compiling" = yes ||
10425 $as_test_x conftest$ac_exeext
10426 }; then
10427 ac_cv_func_shl_load=yes
10428 else
10429 $as_echo "$as_me: failed program was:" >&5
10430 sed 's/^/| /' conftest.$ac_ext >&5
10432 ac_cv_func_shl_load=no
10435 rm -rf conftest.dSYM
10436 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10437 conftest$ac_exeext conftest.$ac_ext
10439 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5
10440 $as_echo "$ac_cv_func_shl_load" >&6; }
10441 if test "x$ac_cv_func_shl_load" = x""yes; then
10442 lt_cv_dlopen="shl_load"
10443 else
10444 { $as_echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
10445 $as_echo_n "checking for shl_load in -ldld... " >&6; }
10446 if test "${ac_cv_lib_dld_shl_load+set}" = set; then
10447 $as_echo_n "(cached) " >&6
10448 else
10449 ac_check_lib_save_LIBS=$LIBS
10450 LIBS="-ldld $LIBS"
10451 cat >conftest.$ac_ext <<_ACEOF
10452 /* confdefs.h. */
10453 _ACEOF
10454 cat confdefs.h >>conftest.$ac_ext
10455 cat >>conftest.$ac_ext <<_ACEOF
10456 /* end confdefs.h. */
10458 /* Override any GCC internal prototype to avoid an error.
10459 Use char because int might match the return type of a GCC
10460 builtin and then its argument prototype would still apply. */
10461 #ifdef __cplusplus
10462 extern "C"
10463 #endif
10464 char shl_load ();
10466 main ()
10468 return shl_load ();
10470 return 0;
10472 _ACEOF
10473 rm -f conftest.$ac_objext conftest$ac_exeext
10474 if { (ac_try="$ac_link"
10475 case "(($ac_try" in
10476 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10477 *) ac_try_echo=$ac_try;;
10478 esac
10479 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10480 $as_echo "$ac_try_echo") >&5
10481 (eval "$ac_link") 2>conftest.er1
10482 ac_status=$?
10483 grep -v '^ *+' conftest.er1 >conftest.err
10484 rm -f conftest.er1
10485 cat conftest.err >&5
10486 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10487 (exit $ac_status); } && {
10488 test -z "$ac_c_werror_flag" ||
10489 test ! -s conftest.err
10490 } && test -s conftest$ac_exeext && {
10491 test "$cross_compiling" = yes ||
10492 $as_test_x conftest$ac_exeext
10493 }; then
10494 ac_cv_lib_dld_shl_load=yes
10495 else
10496 $as_echo "$as_me: failed program was:" >&5
10497 sed 's/^/| /' conftest.$ac_ext >&5
10499 ac_cv_lib_dld_shl_load=no
10502 rm -rf conftest.dSYM
10503 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10504 conftest$ac_exeext conftest.$ac_ext
10505 LIBS=$ac_check_lib_save_LIBS
10507 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
10508 $as_echo "$ac_cv_lib_dld_shl_load" >&6; }
10509 if test "x$ac_cv_lib_dld_shl_load" = x""yes; then
10510 lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
10511 else
10512 { $as_echo "$as_me:$LINENO: checking for dlopen" >&5
10513 $as_echo_n "checking for dlopen... " >&6; }
10514 if test "${ac_cv_func_dlopen+set}" = set; then
10515 $as_echo_n "(cached) " >&6
10516 else
10517 cat >conftest.$ac_ext <<_ACEOF
10518 /* confdefs.h. */
10519 _ACEOF
10520 cat confdefs.h >>conftest.$ac_ext
10521 cat >>conftest.$ac_ext <<_ACEOF
10522 /* end confdefs.h. */
10523 /* Define dlopen to an innocuous variant, in case <limits.h> declares dlopen.
10524 For example, HP-UX 11i <limits.h> declares gettimeofday. */
10525 #define dlopen innocuous_dlopen
10527 /* System header to define __stub macros and hopefully few prototypes,
10528 which can conflict with char dlopen (); below.
10529 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10530 <limits.h> exists even on freestanding compilers. */
10532 #ifdef __STDC__
10533 # include <limits.h>
10534 #else
10535 # include <assert.h>
10536 #endif
10538 #undef dlopen
10540 /* Override any GCC internal prototype to avoid an error.
10541 Use char because int might match the return type of a GCC
10542 builtin and then its argument prototype would still apply. */
10543 #ifdef __cplusplus
10544 extern "C"
10545 #endif
10546 char dlopen ();
10547 /* The GNU C library defines this for functions which it implements
10548 to always fail with ENOSYS. Some functions are actually named
10549 something starting with __ and the normal name is an alias. */
10550 #if defined __stub_dlopen || defined __stub___dlopen
10551 choke me
10552 #endif
10555 main ()
10557 return dlopen ();
10559 return 0;
10561 _ACEOF
10562 rm -f conftest.$ac_objext conftest$ac_exeext
10563 if { (ac_try="$ac_link"
10564 case "(($ac_try" in
10565 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10566 *) ac_try_echo=$ac_try;;
10567 esac
10568 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10569 $as_echo "$ac_try_echo") >&5
10570 (eval "$ac_link") 2>conftest.er1
10571 ac_status=$?
10572 grep -v '^ *+' conftest.er1 >conftest.err
10573 rm -f conftest.er1
10574 cat conftest.err >&5
10575 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10576 (exit $ac_status); } && {
10577 test -z "$ac_c_werror_flag" ||
10578 test ! -s conftest.err
10579 } && test -s conftest$ac_exeext && {
10580 test "$cross_compiling" = yes ||
10581 $as_test_x conftest$ac_exeext
10582 }; then
10583 ac_cv_func_dlopen=yes
10584 else
10585 $as_echo "$as_me: failed program was:" >&5
10586 sed 's/^/| /' conftest.$ac_ext >&5
10588 ac_cv_func_dlopen=no
10591 rm -rf conftest.dSYM
10592 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10593 conftest$ac_exeext conftest.$ac_ext
10595 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
10596 $as_echo "$ac_cv_func_dlopen" >&6; }
10597 if test "x$ac_cv_func_dlopen" = x""yes; then
10598 lt_cv_dlopen="dlopen"
10599 else
10600 { $as_echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
10601 $as_echo_n "checking for dlopen in -ldl... " >&6; }
10602 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
10603 $as_echo_n "(cached) " >&6
10604 else
10605 ac_check_lib_save_LIBS=$LIBS
10606 LIBS="-ldl $LIBS"
10607 cat >conftest.$ac_ext <<_ACEOF
10608 /* confdefs.h. */
10609 _ACEOF
10610 cat confdefs.h >>conftest.$ac_ext
10611 cat >>conftest.$ac_ext <<_ACEOF
10612 /* end confdefs.h. */
10614 /* Override any GCC internal prototype to avoid an error.
10615 Use char because int might match the return type of a GCC
10616 builtin and then its argument prototype would still apply. */
10617 #ifdef __cplusplus
10618 extern "C"
10619 #endif
10620 char dlopen ();
10622 main ()
10624 return dlopen ();
10626 return 0;
10628 _ACEOF
10629 rm -f conftest.$ac_objext conftest$ac_exeext
10630 if { (ac_try="$ac_link"
10631 case "(($ac_try" in
10632 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10633 *) ac_try_echo=$ac_try;;
10634 esac
10635 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10636 $as_echo "$ac_try_echo") >&5
10637 (eval "$ac_link") 2>conftest.er1
10638 ac_status=$?
10639 grep -v '^ *+' conftest.er1 >conftest.err
10640 rm -f conftest.er1
10641 cat conftest.err >&5
10642 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10643 (exit $ac_status); } && {
10644 test -z "$ac_c_werror_flag" ||
10645 test ! -s conftest.err
10646 } && test -s conftest$ac_exeext && {
10647 test "$cross_compiling" = yes ||
10648 $as_test_x conftest$ac_exeext
10649 }; then
10650 ac_cv_lib_dl_dlopen=yes
10651 else
10652 $as_echo "$as_me: failed program was:" >&5
10653 sed 's/^/| /' conftest.$ac_ext >&5
10655 ac_cv_lib_dl_dlopen=no
10658 rm -rf conftest.dSYM
10659 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10660 conftest$ac_exeext conftest.$ac_ext
10661 LIBS=$ac_check_lib_save_LIBS
10663 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
10664 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
10665 if test "x$ac_cv_lib_dl_dlopen" = x""yes; then
10666 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
10667 else
10668 { $as_echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5
10669 $as_echo_n "checking for dlopen in -lsvld... " >&6; }
10670 if test "${ac_cv_lib_svld_dlopen+set}" = set; then
10671 $as_echo_n "(cached) " >&6
10672 else
10673 ac_check_lib_save_LIBS=$LIBS
10674 LIBS="-lsvld $LIBS"
10675 cat >conftest.$ac_ext <<_ACEOF
10676 /* confdefs.h. */
10677 _ACEOF
10678 cat confdefs.h >>conftest.$ac_ext
10679 cat >>conftest.$ac_ext <<_ACEOF
10680 /* end confdefs.h. */
10682 /* Override any GCC internal prototype to avoid an error.
10683 Use char because int might match the return type of a GCC
10684 builtin and then its argument prototype would still apply. */
10685 #ifdef __cplusplus
10686 extern "C"
10687 #endif
10688 char dlopen ();
10690 main ()
10692 return dlopen ();
10694 return 0;
10696 _ACEOF
10697 rm -f conftest.$ac_objext conftest$ac_exeext
10698 if { (ac_try="$ac_link"
10699 case "(($ac_try" in
10700 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10701 *) ac_try_echo=$ac_try;;
10702 esac
10703 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10704 $as_echo "$ac_try_echo") >&5
10705 (eval "$ac_link") 2>conftest.er1
10706 ac_status=$?
10707 grep -v '^ *+' conftest.er1 >conftest.err
10708 rm -f conftest.er1
10709 cat conftest.err >&5
10710 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10711 (exit $ac_status); } && {
10712 test -z "$ac_c_werror_flag" ||
10713 test ! -s conftest.err
10714 } && test -s conftest$ac_exeext && {
10715 test "$cross_compiling" = yes ||
10716 $as_test_x conftest$ac_exeext
10717 }; then
10718 ac_cv_lib_svld_dlopen=yes
10719 else
10720 $as_echo "$as_me: failed program was:" >&5
10721 sed 's/^/| /' conftest.$ac_ext >&5
10723 ac_cv_lib_svld_dlopen=no
10726 rm -rf conftest.dSYM
10727 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10728 conftest$ac_exeext conftest.$ac_ext
10729 LIBS=$ac_check_lib_save_LIBS
10731 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5
10732 $as_echo "$ac_cv_lib_svld_dlopen" >&6; }
10733 if test "x$ac_cv_lib_svld_dlopen" = x""yes; then
10734 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
10735 else
10736 { $as_echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5
10737 $as_echo_n "checking for dld_link in -ldld... " >&6; }
10738 if test "${ac_cv_lib_dld_dld_link+set}" = set; then
10739 $as_echo_n "(cached) " >&6
10740 else
10741 ac_check_lib_save_LIBS=$LIBS
10742 LIBS="-ldld $LIBS"
10743 cat >conftest.$ac_ext <<_ACEOF
10744 /* confdefs.h. */
10745 _ACEOF
10746 cat confdefs.h >>conftest.$ac_ext
10747 cat >>conftest.$ac_ext <<_ACEOF
10748 /* end confdefs.h. */
10750 /* Override any GCC internal prototype to avoid an error.
10751 Use char because int might match the return type of a GCC
10752 builtin and then its argument prototype would still apply. */
10753 #ifdef __cplusplus
10754 extern "C"
10755 #endif
10756 char dld_link ();
10758 main ()
10760 return dld_link ();
10762 return 0;
10764 _ACEOF
10765 rm -f conftest.$ac_objext conftest$ac_exeext
10766 if { (ac_try="$ac_link"
10767 case "(($ac_try" in
10768 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10769 *) ac_try_echo=$ac_try;;
10770 esac
10771 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10772 $as_echo "$ac_try_echo") >&5
10773 (eval "$ac_link") 2>conftest.er1
10774 ac_status=$?
10775 grep -v '^ *+' conftest.er1 >conftest.err
10776 rm -f conftest.er1
10777 cat conftest.err >&5
10778 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10779 (exit $ac_status); } && {
10780 test -z "$ac_c_werror_flag" ||
10781 test ! -s conftest.err
10782 } && test -s conftest$ac_exeext && {
10783 test "$cross_compiling" = yes ||
10784 $as_test_x conftest$ac_exeext
10785 }; then
10786 ac_cv_lib_dld_dld_link=yes
10787 else
10788 $as_echo "$as_me: failed program was:" >&5
10789 sed 's/^/| /' conftest.$ac_ext >&5
10791 ac_cv_lib_dld_dld_link=no
10794 rm -rf conftest.dSYM
10795 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10796 conftest$ac_exeext conftest.$ac_ext
10797 LIBS=$ac_check_lib_save_LIBS
10799 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5
10800 $as_echo "$ac_cv_lib_dld_dld_link" >&6; }
10801 if test "x$ac_cv_lib_dld_dld_link" = x""yes; then
10802 lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
10821 esac
10823 if test "x$lt_cv_dlopen" != xno; then
10824 enable_dlopen=yes
10825 else
10826 enable_dlopen=no
10829 case $lt_cv_dlopen in
10830 dlopen)
10831 save_CPPFLAGS="$CPPFLAGS"
10832 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
10834 save_LDFLAGS="$LDFLAGS"
10835 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
10837 save_LIBS="$LIBS"
10838 LIBS="$lt_cv_dlopen_libs $LIBS"
10840 { $as_echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5
10841 $as_echo_n "checking whether a program can dlopen itself... " >&6; }
10842 if test "${lt_cv_dlopen_self+set}" = set; then
10843 $as_echo_n "(cached) " >&6
10844 else
10845 if test "$cross_compiling" = yes; then :
10846 lt_cv_dlopen_self=cross
10847 else
10848 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
10849 lt_status=$lt_dlunknown
10850 cat > conftest.$ac_ext <<_LT_EOF
10851 #line 10851 "configure"
10852 #include "confdefs.h"
10854 #if HAVE_DLFCN_H
10855 #include <dlfcn.h>
10856 #endif
10858 #include <stdio.h>
10860 #ifdef RTLD_GLOBAL
10861 # define LT_DLGLOBAL RTLD_GLOBAL
10862 #else
10863 # ifdef DL_GLOBAL
10864 # define LT_DLGLOBAL DL_GLOBAL
10865 # else
10866 # define LT_DLGLOBAL 0
10867 # endif
10868 #endif
10870 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
10871 find out it does not work in some platform. */
10872 #ifndef LT_DLLAZY_OR_NOW
10873 # ifdef RTLD_LAZY
10874 # define LT_DLLAZY_OR_NOW RTLD_LAZY
10875 # else
10876 # ifdef DL_LAZY
10877 # define LT_DLLAZY_OR_NOW DL_LAZY
10878 # else
10879 # ifdef RTLD_NOW
10880 # define LT_DLLAZY_OR_NOW RTLD_NOW
10881 # else
10882 # ifdef DL_NOW
10883 # define LT_DLLAZY_OR_NOW DL_NOW
10884 # else
10885 # define LT_DLLAZY_OR_NOW 0
10886 # endif
10887 # endif
10888 # endif
10889 # endif
10890 #endif
10892 void fnord() { int i=42;}
10893 int main ()
10895 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
10896 int status = $lt_dlunknown;
10898 if (self)
10900 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
10901 else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
10902 /* dlclose (self); */
10904 else
10905 puts (dlerror ());
10907 return status;
10909 _LT_EOF
10910 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10911 (eval $ac_link) 2>&5
10912 ac_status=$?
10913 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10914 (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
10915 (./conftest; exit; ) >&5 2>/dev/null
10916 lt_status=$?
10917 case x$lt_status in
10918 x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
10919 x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
10920 x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
10921 esac
10922 else :
10923 # compilation failed
10924 lt_cv_dlopen_self=no
10927 rm -fr conftest*
10931 { $as_echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5
10932 $as_echo "$lt_cv_dlopen_self" >&6; }
10934 if test "x$lt_cv_dlopen_self" = xyes; then
10935 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
10936 { $as_echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5
10937 $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
10938 if test "${lt_cv_dlopen_self_static+set}" = set; then
10939 $as_echo_n "(cached) " >&6
10940 else
10941 if test "$cross_compiling" = yes; then :
10942 lt_cv_dlopen_self_static=cross
10943 else
10944 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
10945 lt_status=$lt_dlunknown
10946 cat > conftest.$ac_ext <<_LT_EOF
10947 #line 10947 "configure"
10948 #include "confdefs.h"
10950 #if HAVE_DLFCN_H
10951 #include <dlfcn.h>
10952 #endif
10954 #include <stdio.h>
10956 #ifdef RTLD_GLOBAL
10957 # define LT_DLGLOBAL RTLD_GLOBAL
10958 #else
10959 # ifdef DL_GLOBAL
10960 # define LT_DLGLOBAL DL_GLOBAL
10961 # else
10962 # define LT_DLGLOBAL 0
10963 # endif
10964 #endif
10966 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
10967 find out it does not work in some platform. */
10968 #ifndef LT_DLLAZY_OR_NOW
10969 # ifdef RTLD_LAZY
10970 # define LT_DLLAZY_OR_NOW RTLD_LAZY
10971 # else
10972 # ifdef DL_LAZY
10973 # define LT_DLLAZY_OR_NOW DL_LAZY
10974 # else
10975 # ifdef RTLD_NOW
10976 # define LT_DLLAZY_OR_NOW RTLD_NOW
10977 # else
10978 # ifdef DL_NOW
10979 # define LT_DLLAZY_OR_NOW DL_NOW
10980 # else
10981 # define LT_DLLAZY_OR_NOW 0
10982 # endif
10983 # endif
10984 # endif
10985 # endif
10986 #endif
10988 void fnord() { int i=42;}
10989 int main ()
10991 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
10992 int status = $lt_dlunknown;
10994 if (self)
10996 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
10997 else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
10998 /* dlclose (self); */
11000 else
11001 puts (dlerror ());
11003 return status;
11005 _LT_EOF
11006 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11007 (eval $ac_link) 2>&5
11008 ac_status=$?
11009 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11010 (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
11011 (./conftest; exit; ) >&5 2>/dev/null
11012 lt_status=$?
11013 case x$lt_status in
11014 x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
11015 x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
11016 x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
11017 esac
11018 else :
11019 # compilation failed
11020 lt_cv_dlopen_self_static=no
11023 rm -fr conftest*
11027 { $as_echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5
11028 $as_echo "$lt_cv_dlopen_self_static" >&6; }
11031 CPPFLAGS="$save_CPPFLAGS"
11032 LDFLAGS="$save_LDFLAGS"
11033 LIBS="$save_LIBS"
11035 esac
11037 case $lt_cv_dlopen_self in
11038 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
11039 *) enable_dlopen_self=unknown ;;
11040 esac
11042 case $lt_cv_dlopen_self_static in
11043 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
11044 *) enable_dlopen_self_static=unknown ;;
11045 esac
11064 striplib=
11065 old_striplib=
11066 { $as_echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5
11067 $as_echo_n "checking whether stripping libraries is possible... " >&6; }
11068 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
11069 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
11070 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
11071 { $as_echo "$as_me:$LINENO: result: yes" >&5
11072 $as_echo "yes" >&6; }
11073 else
11074 # FIXME - insert some real tests, host_os isn't really good enough
11075 case $host_os in
11076 darwin*)
11077 if test -n "$STRIP" ; then
11078 striplib="$STRIP -x"
11079 old_striplib="$STRIP -S"
11080 { $as_echo "$as_me:$LINENO: result: yes" >&5
11081 $as_echo "yes" >&6; }
11082 else
11083 { $as_echo "$as_me:$LINENO: result: no" >&5
11084 $as_echo "no" >&6; }
11088 { $as_echo "$as_me:$LINENO: result: no" >&5
11089 $as_echo "no" >&6; }
11091 esac
11105 # Report which library types will actually be built
11106 { $as_echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5
11107 $as_echo_n "checking if libtool supports shared libraries... " >&6; }
11108 { $as_echo "$as_me:$LINENO: result: $can_build_shared" >&5
11109 $as_echo "$can_build_shared" >&6; }
11111 { $as_echo "$as_me:$LINENO: checking whether to build shared libraries" >&5
11112 $as_echo_n "checking whether to build shared libraries... " >&6; }
11113 test "$can_build_shared" = "no" && enable_shared=no
11115 # On AIX, shared libraries and static libraries use the same namespace, and
11116 # are all built from PIC.
11117 case $host_os in
11118 aix3*)
11119 test "$enable_shared" = yes && enable_static=no
11120 if test -n "$RANLIB"; then
11121 archive_cmds="$archive_cmds~\$RANLIB \$lib"
11122 postinstall_cmds='$RANLIB $lib'
11126 aix[4-9]*)
11127 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
11128 test "$enable_shared" = yes && enable_static=no
11131 esac
11132 { $as_echo "$as_me:$LINENO: result: $enable_shared" >&5
11133 $as_echo "$enable_shared" >&6; }
11135 { $as_echo "$as_me:$LINENO: checking whether to build static libraries" >&5
11136 $as_echo_n "checking whether to build static libraries... " >&6; }
11137 # Make sure either enable_shared or enable_static is yes.
11138 test "$enable_shared" = yes || enable_static=yes
11139 { $as_echo "$as_me:$LINENO: result: $enable_static" >&5
11140 $as_echo "$enable_static" >&6; }
11146 ac_ext=c
11147 ac_cpp='$CPP $CPPFLAGS'
11148 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11149 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11150 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11152 CC="$lt_save_CC"
11166 ac_config_commands="$ac_config_commands libtool"
11171 # Only expand once:
11175 # For testing cross-compilation behaviour.
11176 #cross_compiling=yes
11178 { echo; echo "${term_bold}Optional Platform Environment:${term_norm}"; } >& 6
11181 for ac_header in sys/signal.h
11183 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11184 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11185 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11186 $as_echo_n "checking for $ac_header... " >&6; }
11187 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11188 $as_echo_n "(cached) " >&6
11190 ac_res=`eval 'as_val=${'$as_ac_Header'}
11191 $as_echo "$as_val"'`
11192 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11193 $as_echo "$ac_res" >&6; }
11194 else
11195 # Is the header compilable?
11196 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11197 $as_echo_n "checking $ac_header usability... " >&6; }
11198 cat >conftest.$ac_ext <<_ACEOF
11199 /* confdefs.h. */
11200 _ACEOF
11201 cat confdefs.h >>conftest.$ac_ext
11202 cat >>conftest.$ac_ext <<_ACEOF
11203 /* end confdefs.h. */
11204 $ac_includes_default
11205 #include <$ac_header>
11206 _ACEOF
11207 rm -f conftest.$ac_objext
11208 if { (ac_try="$ac_compile"
11209 case "(($ac_try" in
11210 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11211 *) ac_try_echo=$ac_try;;
11212 esac
11213 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11214 $as_echo "$ac_try_echo") >&5
11215 (eval "$ac_compile") 2>conftest.er1
11216 ac_status=$?
11217 grep -v '^ *+' conftest.er1 >conftest.err
11218 rm -f conftest.er1
11219 cat conftest.err >&5
11220 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11221 (exit $ac_status); } && {
11222 test -z "$ac_c_werror_flag" ||
11223 test ! -s conftest.err
11224 } && test -s conftest.$ac_objext; then
11225 ac_header_compiler=yes
11226 else
11227 $as_echo "$as_me: failed program was:" >&5
11228 sed 's/^/| /' conftest.$ac_ext >&5
11230 ac_header_compiler=no
11233 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11234 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11235 $as_echo "$ac_header_compiler" >&6; }
11237 # Is the header present?
11238 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11239 $as_echo_n "checking $ac_header presence... " >&6; }
11240 cat >conftest.$ac_ext <<_ACEOF
11241 /* confdefs.h. */
11242 _ACEOF
11243 cat confdefs.h >>conftest.$ac_ext
11244 cat >>conftest.$ac_ext <<_ACEOF
11245 /* end confdefs.h. */
11246 #include <$ac_header>
11247 _ACEOF
11248 if { (ac_try="$ac_cpp conftest.$ac_ext"
11249 case "(($ac_try" in
11250 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11251 *) ac_try_echo=$ac_try;;
11252 esac
11253 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11254 $as_echo "$ac_try_echo") >&5
11255 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11256 ac_status=$?
11257 grep -v '^ *+' conftest.er1 >conftest.err
11258 rm -f conftest.er1
11259 cat conftest.err >&5
11260 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11261 (exit $ac_status); } >/dev/null && {
11262 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11263 test ! -s conftest.err
11264 }; then
11265 ac_header_preproc=yes
11266 else
11267 $as_echo "$as_me: failed program was:" >&5
11268 sed 's/^/| /' conftest.$ac_ext >&5
11270 ac_header_preproc=no
11273 rm -f conftest.err conftest.$ac_ext
11274 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11275 $as_echo "$ac_header_preproc" >&6; }
11277 # So? What about this header?
11278 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11279 yes:no: )
11280 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11281 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11282 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11283 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11284 ac_header_preproc=yes
11286 no:yes:* )
11287 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11288 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11289 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
11290 $as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
11291 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11292 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11293 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
11294 $as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
11295 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11296 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11297 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11298 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11301 esac
11302 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11303 $as_echo_n "checking for $ac_header... " >&6; }
11304 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11305 $as_echo_n "(cached) " >&6
11306 else
11307 eval "$as_ac_Header=\$ac_header_preproc"
11309 ac_res=`eval 'as_val=${'$as_ac_Header'}
11310 $as_echo "$as_val"'`
11311 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11312 $as_echo "$ac_res" >&6; }
11315 as_val=`eval 'as_val=${'$as_ac_Header'}
11316 $as_echo "$as_val"'`
11317 if test "x$as_val" = x""yes; then
11318 cat >>confdefs.h <<_ACEOF
11319 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11320 _ACEOF
11324 done
11327 case "$host_os" in
11328 sunos4* | freebsd* | dragonfly* | openbsd* | netbsd* | kfreebsd* | knetbsd*)
11329 CFG_SIGNALS=signals-bsd.h ;;
11330 hpux*)
11331 CFG_SIGNALS=signals-hpux.h ;;
11332 macos* | darwin*)
11333 CFG_SIGNALS=signals-macos.h ;;
11334 gnu*)
11335 CFG_SIGNALS=signals-hurd.h ;;
11337 CFG_SIGNALS=signals.h ;;
11338 esac
11340 cat >>confdefs.h <<_ACEOF
11341 #define CFG_SIGNALS "$CFG_SIGNALS"
11342 _ACEOF
11345 # How to determine the memory page size.
11350 for ac_header in unistd.h
11352 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11353 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11354 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11355 $as_echo_n "checking for $ac_header... " >&6; }
11356 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11357 $as_echo_n "(cached) " >&6
11359 ac_res=`eval 'as_val=${'$as_ac_Header'}
11360 $as_echo "$as_val"'`
11361 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11362 $as_echo "$ac_res" >&6; }
11363 else
11364 # Is the header compilable?
11365 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11366 $as_echo_n "checking $ac_header usability... " >&6; }
11367 cat >conftest.$ac_ext <<_ACEOF
11368 /* confdefs.h. */
11369 _ACEOF
11370 cat confdefs.h >>conftest.$ac_ext
11371 cat >>conftest.$ac_ext <<_ACEOF
11372 /* end confdefs.h. */
11373 $ac_includes_default
11374 #include <$ac_header>
11375 _ACEOF
11376 rm -f conftest.$ac_objext
11377 if { (ac_try="$ac_compile"
11378 case "(($ac_try" in
11379 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11380 *) ac_try_echo=$ac_try;;
11381 esac
11382 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11383 $as_echo "$ac_try_echo") >&5
11384 (eval "$ac_compile") 2>conftest.er1
11385 ac_status=$?
11386 grep -v '^ *+' conftest.er1 >conftest.err
11387 rm -f conftest.er1
11388 cat conftest.err >&5
11389 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11390 (exit $ac_status); } && {
11391 test -z "$ac_c_werror_flag" ||
11392 test ! -s conftest.err
11393 } && test -s conftest.$ac_objext; then
11394 ac_header_compiler=yes
11395 else
11396 $as_echo "$as_me: failed program was:" >&5
11397 sed 's/^/| /' conftest.$ac_ext >&5
11399 ac_header_compiler=no
11402 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11403 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11404 $as_echo "$ac_header_compiler" >&6; }
11406 # Is the header present?
11407 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11408 $as_echo_n "checking $ac_header presence... " >&6; }
11409 cat >conftest.$ac_ext <<_ACEOF
11410 /* confdefs.h. */
11411 _ACEOF
11412 cat confdefs.h >>conftest.$ac_ext
11413 cat >>conftest.$ac_ext <<_ACEOF
11414 /* end confdefs.h. */
11415 #include <$ac_header>
11416 _ACEOF
11417 if { (ac_try="$ac_cpp conftest.$ac_ext"
11418 case "(($ac_try" in
11419 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11420 *) ac_try_echo=$ac_try;;
11421 esac
11422 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11423 $as_echo "$ac_try_echo") >&5
11424 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11425 ac_status=$?
11426 grep -v '^ *+' conftest.er1 >conftest.err
11427 rm -f conftest.er1
11428 cat conftest.err >&5
11429 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11430 (exit $ac_status); } >/dev/null && {
11431 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11432 test ! -s conftest.err
11433 }; then
11434 ac_header_preproc=yes
11435 else
11436 $as_echo "$as_me: failed program was:" >&5
11437 sed 's/^/| /' conftest.$ac_ext >&5
11439 ac_header_preproc=no
11442 rm -f conftest.err conftest.$ac_ext
11443 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11444 $as_echo "$ac_header_preproc" >&6; }
11446 # So? What about this header?
11447 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11448 yes:no: )
11449 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11450 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11451 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11452 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11453 ac_header_preproc=yes
11455 no:yes:* )
11456 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11457 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11458 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
11459 $as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
11460 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11461 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11462 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
11463 $as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
11464 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11465 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11466 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11467 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11470 esac
11471 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11472 $as_echo_n "checking for $ac_header... " >&6; }
11473 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11474 $as_echo_n "(cached) " >&6
11475 else
11476 eval "$as_ac_Header=\$ac_header_preproc"
11478 ac_res=`eval 'as_val=${'$as_ac_Header'}
11479 $as_echo "$as_val"'`
11480 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11481 $as_echo "$ac_res" >&6; }
11484 as_val=`eval 'as_val=${'$as_ac_Header'}
11485 $as_echo "$as_val"'`
11486 if test "x$as_val" = x""yes; then
11487 cat >>confdefs.h <<_ACEOF
11488 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11489 _ACEOF
11493 done
11497 { $as_echo "$as_me:$LINENO: checking for getpagesize" >&5
11498 $as_echo_n "checking for getpagesize... " >&6; }
11499 if test "${sv_cv_func_getpagesize+set}" = set; then
11500 $as_echo_n "(cached) " >&6
11501 else
11503 cat >conftest.$ac_ext <<_ACEOF
11505 /* confdefs.h. */
11506 _ACEOF
11507 cat confdefs.h >>conftest.$ac_ext
11508 cat >>conftest.$ac_ext <<_ACEOF
11509 /* end confdefs.h. */
11511 #if HAVE_UNISTD_H
11512 #include <sys/types.h>
11513 #include <unistd.h>
11514 #endif
11517 main ()
11519 int pgsz = getpagesize();
11521 return 0;
11523 _ACEOF
11524 rm -f conftest.$ac_objext conftest$ac_exeext
11525 if { (ac_try="$ac_link"
11526 case "(($ac_try" in
11527 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11528 *) ac_try_echo=$ac_try;;
11529 esac
11530 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11531 $as_echo "$ac_try_echo") >&5
11532 (eval "$ac_link") 2>conftest.er1
11533 ac_status=$?
11534 grep -v '^ *+' conftest.er1 >conftest.err
11535 rm -f conftest.er1
11536 cat conftest.err >&5
11537 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11538 (exit $ac_status); } && {
11539 test -z "$ac_c_werror_flag" ||
11540 test ! -s conftest.err
11541 } && test -s conftest$ac_exeext && {
11542 test "$cross_compiling" = yes ||
11543 $as_test_x conftest$ac_exeext
11544 }; then
11545 sv_cv_func_getpagesize=yes
11546 else
11547 $as_echo "$as_me: failed program was:" >&5
11548 sed 's/^/| /' conftest.$ac_ext >&5
11550 sv_cv_func_getpagesize=no
11553 rm -rf conftest.dSYM
11554 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11555 conftest$ac_exeext conftest.$ac_ext
11557 { $as_echo "$as_me:$LINENO: result: $sv_cv_func_getpagesize" >&5
11558 $as_echo "$sv_cv_func_getpagesize" >&6; }
11559 if test $sv_cv_func_getpagesize = yes; then
11561 cat >>confdefs.h <<\_ACEOF
11562 #define HAVE_GETPAGESIZE 1
11563 _ACEOF
11568 { $as_echo "$as_me:$LINENO: checking for sysconf(_SC_PAGESIZE)" >&5
11569 $as_echo_n "checking for sysconf(_SC_PAGESIZE)... " >&6; }
11570 if test "${sv_cv_func_sysconf_pagesize+set}" = set; then
11571 $as_echo_n "(cached) " >&6
11572 else
11574 cat >conftest.$ac_ext <<_ACEOF
11576 /* confdefs.h. */
11577 _ACEOF
11578 cat confdefs.h >>conftest.$ac_ext
11579 cat >>conftest.$ac_ext <<_ACEOF
11580 /* end confdefs.h. */
11582 #if HAVE_UNISTD_H
11583 #include <sys/types.h>
11584 #include <unistd.h>
11585 #endif
11588 main ()
11590 int pgsz = sysconf (_SC_PAGESIZE);
11592 return 0;
11594 _ACEOF
11595 rm -f conftest.$ac_objext conftest$ac_exeext
11596 if { (ac_try="$ac_link"
11597 case "(($ac_try" in
11598 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11599 *) ac_try_echo=$ac_try;;
11600 esac
11601 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11602 $as_echo "$ac_try_echo") >&5
11603 (eval "$ac_link") 2>conftest.er1
11604 ac_status=$?
11605 grep -v '^ *+' conftest.er1 >conftest.err
11606 rm -f conftest.er1
11607 cat conftest.err >&5
11608 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11609 (exit $ac_status); } && {
11610 test -z "$ac_c_werror_flag" ||
11611 test ! -s conftest.err
11612 } && test -s conftest$ac_exeext && {
11613 test "$cross_compiling" = yes ||
11614 $as_test_x conftest$ac_exeext
11615 }; then
11616 sv_cv_func_sysconf_pagesize=yes
11617 else
11618 $as_echo "$as_me: failed program was:" >&5
11619 sed 's/^/| /' conftest.$ac_ext >&5
11621 sv_cv_func_sysconf_pagesize=no
11624 rm -rf conftest.dSYM
11625 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11626 conftest$ac_exeext conftest.$ac_ext
11628 { $as_echo "$as_me:$LINENO: result: $sv_cv_func_sysconf_pagesize" >&5
11629 $as_echo "$sv_cv_func_sysconf_pagesize" >&6; }
11630 if test $sv_cv_func_sysconf_pagesize = yes; then
11632 cat >>confdefs.h <<\_ACEOF
11633 #define HAVE_SYSCONF_PAGESIZE 1
11634 _ACEOF
11639 { $as_echo "$as_me:$LINENO: checking for PAGESIZE in limits.h" >&5
11640 $as_echo_n "checking for PAGESIZE in limits.h... " >&6; }
11641 if test "${sv_cv_macro_pagesize+set}" = set; then
11642 $as_echo_n "(cached) " >&6
11643 else
11645 cat >conftest.$ac_ext <<_ACEOF
11647 /* confdefs.h. */
11648 _ACEOF
11649 cat confdefs.h >>conftest.$ac_ext
11650 cat >>conftest.$ac_ext <<_ACEOF
11651 /* end confdefs.h. */
11652 #include <limits.h>
11654 main ()
11656 int pgsz = PAGESIZE;
11658 return 0;
11660 _ACEOF
11661 rm -f conftest.$ac_objext conftest$ac_exeext
11662 if { (ac_try="$ac_link"
11663 case "(($ac_try" in
11664 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11665 *) ac_try_echo=$ac_try;;
11666 esac
11667 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11668 $as_echo "$ac_try_echo") >&5
11669 (eval "$ac_link") 2>conftest.er1
11670 ac_status=$?
11671 grep -v '^ *+' conftest.er1 >conftest.err
11672 rm -f conftest.er1
11673 cat conftest.err >&5
11674 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11675 (exit $ac_status); } && {
11676 test -z "$ac_c_werror_flag" ||
11677 test ! -s conftest.err
11678 } && test -s conftest$ac_exeext && {
11679 test "$cross_compiling" = yes ||
11680 $as_test_x conftest$ac_exeext
11681 }; then
11682 sv_cv_macro_pagesize=yes
11683 else
11684 $as_echo "$as_me: failed program was:" >&5
11685 sed 's/^/| /' conftest.$ac_ext >&5
11687 sv_cv_macro_pagesize=no
11690 rm -rf conftest.dSYM
11691 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11692 conftest$ac_exeext conftest.$ac_ext
11694 { $as_echo "$as_me:$LINENO: result: $sv_cv_macro_pagesize" >&5
11695 $as_echo "$sv_cv_macro_pagesize" >&6; }
11696 if test $sv_cv_macro_pagesize = yes; then
11698 cat >>confdefs.h <<\_ACEOF
11699 #define HAVE_PAGESIZE 1
11700 _ACEOF
11706 # How to allocate fresh memory using mmap.
11707 # (We need mmap, because mprotect() doesn't work on malloc()ed memory on
11708 # some systems.)
11714 { $as_echo "$as_me:$LINENO: checking for mmap with MAP_ANON" >&5
11715 $as_echo_n "checking for mmap with MAP_ANON... " >&6; }
11716 if test "${sv_cv_func_mmap_anon+set}" = set; then
11717 $as_echo_n "(cached) " >&6
11718 else
11720 if test "$cross_compiling" = yes; then
11722 case "$host_os" in
11723 freebsd* | linux* | osf* | darwin*)
11724 sv_cv_func_mmap_anon=yes ;;
11726 cat >conftest.$ac_ext <<_ACEOF
11728 /* confdefs.h. */
11729 _ACEOF
11730 cat confdefs.h >>conftest.$ac_ext
11731 cat >>conftest.$ac_ext <<_ACEOF
11732 /* end confdefs.h. */
11734 #include <sys/types.h>
11735 #include <sys/mman.h>
11738 main ()
11740 mmap (0, 0x10000, PROT_READ | PROT_WRITE, MAP_ANON | MAP_PRIVATE, -1, 0);
11742 return 0;
11744 _ACEOF
11745 rm -f conftest.$ac_objext conftest$ac_exeext
11746 if { (ac_try="$ac_link"
11747 case "(($ac_try" in
11748 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11749 *) ac_try_echo=$ac_try;;
11750 esac
11751 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11752 $as_echo "$ac_try_echo") >&5
11753 (eval "$ac_link") 2>conftest.er1
11754 ac_status=$?
11755 grep -v '^ *+' conftest.er1 >conftest.err
11756 rm -f conftest.er1
11757 cat conftest.err >&5
11758 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11759 (exit $ac_status); } && {
11760 test -z "$ac_c_werror_flag" ||
11761 test ! -s conftest.err
11762 } && test -s conftest$ac_exeext && {
11763 test "$cross_compiling" = yes ||
11764 $as_test_x conftest$ac_exeext
11765 }; then
11766 sv_cv_func_mmap_anon="guessing yes"
11767 else
11768 $as_echo "$as_me: failed program was:" >&5
11769 sed 's/^/| /' conftest.$ac_ext >&5
11771 sv_cv_func_mmap_anon=no
11774 rm -rf conftest.dSYM
11775 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11776 conftest$ac_exeext conftest.$ac_ext
11778 esac
11780 else
11781 cat >conftest.$ac_ext <<_ACEOF
11783 /* confdefs.h. */
11784 _ACEOF
11785 cat confdefs.h >>conftest.$ac_ext
11786 cat >>conftest.$ac_ext <<_ACEOF
11787 /* end confdefs.h. */
11789 #include <sys/types.h>
11790 #include <sys/mman.h>
11791 int main ()
11793 void *p = mmap (0, 0x10000, PROT_READ | PROT_WRITE, MAP_ANON | MAP_PRIVATE, -1, 0);
11794 return (p == (void *)(-1));
11796 _ACEOF
11797 rm -f conftest$ac_exeext
11798 if { (ac_try="$ac_link"
11799 case "(($ac_try" in
11800 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11801 *) ac_try_echo=$ac_try;;
11802 esac
11803 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11804 $as_echo "$ac_try_echo") >&5
11805 (eval "$ac_link") 2>&5
11806 ac_status=$?
11807 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11808 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11809 { (case "(($ac_try" in
11810 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11811 *) ac_try_echo=$ac_try;;
11812 esac
11813 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11814 $as_echo "$ac_try_echo") >&5
11815 (eval "$ac_try") 2>&5
11816 ac_status=$?
11817 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11818 (exit $ac_status); }; }; then
11819 sv_cv_func_mmap_anon=yes
11820 else
11821 $as_echo "$as_me: program exited with status $ac_status" >&5
11822 $as_echo "$as_me: failed program was:" >&5
11823 sed 's/^/| /' conftest.$ac_ext >&5
11825 ( exit $ac_status )
11826 sv_cv_func_mmap_anon=no
11828 rm -rf conftest.dSYM
11829 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
11835 { $as_echo "$as_me:$LINENO: result: $sv_cv_func_mmap_anon" >&5
11836 $as_echo "$sv_cv_func_mmap_anon" >&6; }
11837 if test "$sv_cv_func_mmap_anon" != no; then
11839 cat >>confdefs.h <<\_ACEOF
11840 #define HAVE_MMAP_ANON 1
11841 _ACEOF
11846 { $as_echo "$as_me:$LINENO: checking for mmap with MAP_ANONYMOUS" >&5
11847 $as_echo_n "checking for mmap with MAP_ANONYMOUS... " >&6; }
11848 if test "${sv_cv_func_mmap_anonymous+set}" = set; then
11849 $as_echo_n "(cached) " >&6
11850 else
11852 if test "$cross_compiling" = yes; then
11854 case "$host_os" in
11855 hpux* | linux* | osf*)
11856 sv_cv_func_mmap_anonymous=yes ;;
11857 darwin*)
11858 sv_cv_func_mmap_anonymous=no ;;
11860 cat >conftest.$ac_ext <<_ACEOF
11862 /* confdefs.h. */
11863 _ACEOF
11864 cat confdefs.h >>conftest.$ac_ext
11865 cat >>conftest.$ac_ext <<_ACEOF
11866 /* end confdefs.h. */
11868 #include <sys/types.h>
11869 #include <sys/mman.h>
11872 main ()
11874 mmap (0, 0x10000, PROT_READ | PROT_WRITE, MAP_ANONYMOUS | MAP_PRIVATE, -1, 0);
11876 return 0;
11878 _ACEOF
11879 rm -f conftest.$ac_objext conftest$ac_exeext
11880 if { (ac_try="$ac_link"
11881 case "(($ac_try" in
11882 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11883 *) ac_try_echo=$ac_try;;
11884 esac
11885 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11886 $as_echo "$ac_try_echo") >&5
11887 (eval "$ac_link") 2>conftest.er1
11888 ac_status=$?
11889 grep -v '^ *+' conftest.er1 >conftest.err
11890 rm -f conftest.er1
11891 cat conftest.err >&5
11892 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11893 (exit $ac_status); } && {
11894 test -z "$ac_c_werror_flag" ||
11895 test ! -s conftest.err
11896 } && test -s conftest$ac_exeext && {
11897 test "$cross_compiling" = yes ||
11898 $as_test_x conftest$ac_exeext
11899 }; then
11900 sv_cv_func_mmap_anonymous="guessing yes"
11901 else
11902 $as_echo "$as_me: failed program was:" >&5
11903 sed 's/^/| /' conftest.$ac_ext >&5
11905 sv_cv_func_mmap_anonymous=no
11908 rm -rf conftest.dSYM
11909 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11910 conftest$ac_exeext conftest.$ac_ext
11912 esac
11914 else
11915 cat >conftest.$ac_ext <<_ACEOF
11917 /* confdefs.h. */
11918 _ACEOF
11919 cat confdefs.h >>conftest.$ac_ext
11920 cat >>conftest.$ac_ext <<_ACEOF
11921 /* end confdefs.h. */
11923 #include <sys/types.h>
11924 #include <sys/mman.h>
11925 int main ()
11927 void *p = mmap (0, 0x10000, PROT_READ | PROT_WRITE, MAP_ANONYMOUS | MAP_PRIVATE, -1, 0);
11928 return (p == (void *)(-1));
11930 _ACEOF
11931 rm -f conftest$ac_exeext
11932 if { (ac_try="$ac_link"
11933 case "(($ac_try" in
11934 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11935 *) ac_try_echo=$ac_try;;
11936 esac
11937 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11938 $as_echo "$ac_try_echo") >&5
11939 (eval "$ac_link") 2>&5
11940 ac_status=$?
11941 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11942 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11943 { (case "(($ac_try" in
11944 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11945 *) ac_try_echo=$ac_try;;
11946 esac
11947 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11948 $as_echo "$ac_try_echo") >&5
11949 (eval "$ac_try") 2>&5
11950 ac_status=$?
11951 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11952 (exit $ac_status); }; }; then
11953 sv_cv_func_mmap_anonymous=yes
11954 else
11955 $as_echo "$as_me: program exited with status $ac_status" >&5
11956 $as_echo "$as_me: failed program was:" >&5
11957 sed 's/^/| /' conftest.$ac_ext >&5
11959 ( exit $ac_status )
11960 sv_cv_func_mmap_anonymous=no
11962 rm -rf conftest.dSYM
11963 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
11969 { $as_echo "$as_me:$LINENO: result: $sv_cv_func_mmap_anonymous" >&5
11970 $as_echo "$sv_cv_func_mmap_anonymous" >&6; }
11971 if test "$sv_cv_func_mmap_anonymous" != no; then
11973 cat >>confdefs.h <<\_ACEOF
11974 #define HAVE_MMAP_ANONYMOUS 1
11975 _ACEOF
11980 { $as_echo "$as_me:$LINENO: checking for mmap of /dev/zero" >&5
11981 $as_echo_n "checking for mmap of /dev/zero... " >&6; }
11982 if test "${sv_cv_func_mmap_devzero+set}" = set; then
11983 $as_echo_n "(cached) " >&6
11984 else
11986 if test "$cross_compiling" = yes; then
11988 case "$host_os" in
11989 freebsd* | irix* | linux* | osf* | solaris* | sunos4*)
11990 sv_cv_func_mmap_devzero=yes ;;
11991 darwin*)
11992 sv_cv_func_mmap_devzero=no ;;
11994 cat >conftest.$ac_ext <<_ACEOF
11996 /* confdefs.h. */
11997 _ACEOF
11998 cat confdefs.h >>conftest.$ac_ext
11999 cat >>conftest.$ac_ext <<_ACEOF
12000 /* end confdefs.h. */
12002 #include <sys/types.h>
12003 #include <sys/mman.h>
12004 #ifndef MAP_FILE
12005 #define MAP_FILE 0
12006 #endif
12009 main ()
12011 mmap (0, 0x10000, PROT_READ | PROT_WRITE, MAP_FILE | MAP_PRIVATE, 7, 0);
12013 return 0;
12015 _ACEOF
12016 rm -f conftest.$ac_objext conftest$ac_exeext
12017 if { (ac_try="$ac_link"
12018 case "(($ac_try" in
12019 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12020 *) ac_try_echo=$ac_try;;
12021 esac
12022 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12023 $as_echo "$ac_try_echo") >&5
12024 (eval "$ac_link") 2>conftest.er1
12025 ac_status=$?
12026 grep -v '^ *+' conftest.er1 >conftest.err
12027 rm -f conftest.er1
12028 cat conftest.err >&5
12029 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12030 (exit $ac_status); } && {
12031 test -z "$ac_c_werror_flag" ||
12032 test ! -s conftest.err
12033 } && test -s conftest$ac_exeext && {
12034 test "$cross_compiling" = yes ||
12035 $as_test_x conftest$ac_exeext
12036 }; then
12037 sv_cv_func_mmap_devzero="guessing yes"
12038 else
12039 $as_echo "$as_me: failed program was:" >&5
12040 sed 's/^/| /' conftest.$ac_ext >&5
12042 sv_cv_func_mmap_devzero=no
12045 rm -rf conftest.dSYM
12046 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12047 conftest$ac_exeext conftest.$ac_ext
12049 esac
12051 else
12052 cat >conftest.$ac_ext <<_ACEOF
12054 /* confdefs.h. */
12055 _ACEOF
12056 cat confdefs.h >>conftest.$ac_ext
12057 cat >>conftest.$ac_ext <<_ACEOF
12058 /* end confdefs.h. */
12060 #include <sys/types.h>
12061 #include <sys/mman.h>
12062 #include <fcntl.h>
12063 #ifndef MAP_FILE
12064 #define MAP_FILE 0
12065 #endif
12066 int main ()
12068 int fd;
12069 void *p;
12070 fd = open ("/dev/zero", O_RDONLY, 0666);
12071 if (fd < 0) return 1;
12072 p = mmap (0, 0x10000, PROT_READ | PROT_WRITE, MAP_FILE | MAP_PRIVATE, fd, 0);
12073 return (p == (void *)(-1));
12075 _ACEOF
12076 rm -f conftest$ac_exeext
12077 if { (ac_try="$ac_link"
12078 case "(($ac_try" in
12079 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12080 *) ac_try_echo=$ac_try;;
12081 esac
12082 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12083 $as_echo "$ac_try_echo") >&5
12084 (eval "$ac_link") 2>&5
12085 ac_status=$?
12086 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12087 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12088 { (case "(($ac_try" in
12089 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12090 *) ac_try_echo=$ac_try;;
12091 esac
12092 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12093 $as_echo "$ac_try_echo") >&5
12094 (eval "$ac_try") 2>&5
12095 ac_status=$?
12096 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12097 (exit $ac_status); }; }; then
12098 sv_cv_func_mmap_devzero=yes
12099 else
12100 $as_echo "$as_me: program exited with status $ac_status" >&5
12101 $as_echo "$as_me: failed program was:" >&5
12102 sed 's/^/| /' conftest.$ac_ext >&5
12104 ( exit $ac_status )
12105 sv_cv_func_mmap_devzero=no
12107 rm -rf conftest.dSYM
12108 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12114 { $as_echo "$as_me:$LINENO: result: $sv_cv_func_mmap_devzero" >&5
12115 $as_echo "$sv_cv_func_mmap_devzero" >&6; }
12116 if test "$sv_cv_func_mmap_devzero" != no; then
12118 cat >>confdefs.h <<\_ACEOF
12119 #define HAVE_MMAP_DEVZERO 1
12120 _ACEOF
12125 # How to write a SIGSEGV handler with access to the fault address.
12127 # On MacOS X 10.2 or newer, we don't need these tests, because we'll end up
12128 # using handler-macos.c anyway. If we were to perform the tests, 5 Crash Report
12129 # dialog windows would pop up.
12130 case "$host_os" in
12131 macos* | darwin[6-9]* | darwin[1-9][0-9]*) ;;
12138 { $as_echo "$as_me:$LINENO: checking whether a fault handler according to POSIX works" >&5
12139 $as_echo_n "checking whether a fault handler according to POSIX works... " >&6; }
12140 if test "${sv_cv_fault_posix+set}" = set; then
12141 $as_echo_n "(cached) " >&6
12142 else
12144 if test "$cross_compiling" = yes; then
12145 case "$host" in
12146 *-*-solaris2.[7-9] | i?86-*-linux2.[4-9]* | i?86-*-freebsd[4-9]* | alpha*-dec-osf[4-9]* | *-*-hpux11* | mips-sgi-irix6*) sv_cv_fault_posix=yes ;;
12148 cat >conftest.$ac_ext <<_ACEOF
12150 /* confdefs.h. */
12151 _ACEOF
12152 cat confdefs.h >>conftest.$ac_ext
12153 cat >>conftest.$ac_ext <<_ACEOF
12154 /* end confdefs.h. */
12156 #include <signal.h>
12158 void sigsegv_handler (int sig, siginfo_t *sip, void *ucp)
12160 void *fault_address = (void *) (sip->si_addr);
12164 main ()
12166 struct sigaction action;
12167 action.sa_sigaction = &sigsegv_handler;
12168 action.sa_flags = SA_SIGINFO;
12170 return 0;
12172 _ACEOF
12173 rm -f conftest.$ac_objext conftest$ac_exeext
12174 if { (ac_try="$ac_link"
12175 case "(($ac_try" in
12176 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12177 *) ac_try_echo=$ac_try;;
12178 esac
12179 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12180 $as_echo "$ac_try_echo") >&5
12181 (eval "$ac_link") 2>conftest.er1
12182 ac_status=$?
12183 grep -v '^ *+' conftest.er1 >conftest.err
12184 rm -f conftest.er1
12185 cat conftest.err >&5
12186 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12187 (exit $ac_status); } && {
12188 test -z "$ac_c_werror_flag" ||
12189 test ! -s conftest.err
12190 } && test -s conftest$ac_exeext && {
12191 test "$cross_compiling" = yes ||
12192 $as_test_x conftest$ac_exeext
12193 }; then
12194 sv_cv_fault_posix="guessing no"
12195 else
12196 $as_echo "$as_me: failed program was:" >&5
12197 sed 's/^/| /' conftest.$ac_ext >&5
12199 sv_cv_fault_posix=no
12202 rm -rf conftest.dSYM
12203 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12204 conftest$ac_exeext conftest.$ac_ext
12206 esac
12208 else
12209 cat >conftest.$ac_ext <<_ACEOF
12211 /* confdefs.h. */
12212 _ACEOF
12213 cat confdefs.h >>conftest.$ac_ext
12214 cat >>conftest.$ac_ext <<_ACEOF
12215 /* end confdefs.h. */
12217 #include <stdlib.h>
12218 #include <signal.h>
12219 #if HAVE_SYS_SIGNAL_H
12220 # include <sys/signal.h>
12221 #endif
12223 #include <sys/types.h>
12224 #include <sys/mman.h>
12225 #if HAVE_MMAP_DEVZERO
12226 # include <fcntl.h>
12227 # ifndef MAP_FILE
12228 # define MAP_FILE 0
12229 # endif
12230 #endif
12231 #ifndef PROT_NONE
12232 # define PROT_NONE 0
12233 #endif
12234 #if HAVE_MMAP_ANON
12235 # define zero_fd -1
12236 # define map_flags MAP_ANON | MAP_PRIVATE
12237 #elif HAVE_MMAP_ANONYMOUS
12238 # define zero_fd -1
12239 # define map_flags MAP_ANONYMOUS | MAP_PRIVATE
12240 #elif HAVE_MMAP_DEVZERO
12241 static int zero_fd;
12242 # define map_flags MAP_FILE | MAP_PRIVATE
12243 #endif
12244 unsigned long page;
12245 int handler_called = 0;
12246 void sigsegv_handler (int sig, siginfo_t *sip, void *ucp)
12248 void *fault_address = (void *) (sip->si_addr);
12249 handler_called++;
12250 if (handler_called == 10)
12251 exit (4);
12252 if (fault_address != (void*)(page + 0x678))
12253 exit (3);
12254 if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
12255 exit (2);
12257 void crasher (unsigned long p)
12259 *(int *) (p + 0x678) = 42;
12261 int main ()
12263 void *p;
12264 struct sigaction action;
12265 /* Preparations. */
12266 #if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
12267 zero_fd = open ("/dev/zero", O_RDONLY, 0644);
12268 #endif
12269 /* Setup some mmaped memory. */
12270 #ifdef __hpux
12271 /* HP-UX 10 mmap() often fails when given a hint. So give the OS complete
12272 freedom about the address range. */
12273 p = mmap ((void *) 0, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
12274 #else
12275 p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
12276 #endif
12277 if (p == (void *)(-1))
12278 exit (2);
12279 page = (unsigned long) p;
12280 /* Make it read-only. */
12281 if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
12282 exit (2);
12283 /* Install the SIGSEGV handler. */
12284 sigemptyset(&action.sa_mask);
12285 action.sa_sigaction = &sigsegv_handler;
12286 action.sa_flags = SA_SIGINFO;
12287 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
12288 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
12289 /* The first write access should invoke the handler and then complete. */
12290 crasher (page);
12291 /* The second write access should not invoke the handler. */
12292 crasher (page);
12293 /* Check that the handler was called only once. */
12294 if (handler_called != 1)
12295 exit (1);
12296 /* Test passed! */
12297 return 0;
12299 _ACEOF
12300 rm -f conftest$ac_exeext
12301 if { (ac_try="$ac_link"
12302 case "(($ac_try" in
12303 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12304 *) ac_try_echo=$ac_try;;
12305 esac
12306 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12307 $as_echo "$ac_try_echo") >&5
12308 (eval "$ac_link") 2>&5
12309 ac_status=$?
12310 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12311 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12312 { (case "(($ac_try" in
12313 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12314 *) ac_try_echo=$ac_try;;
12315 esac
12316 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12317 $as_echo "$ac_try_echo") >&5
12318 (eval "$ac_try") 2>&5
12319 ac_status=$?
12320 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12321 (exit $ac_status); }; }; then
12322 sv_cv_fault_posix=yes
12323 else
12324 $as_echo "$as_me: program exited with status $ac_status" >&5
12325 $as_echo "$as_me: failed program was:" >&5
12326 sed 's/^/| /' conftest.$ac_ext >&5
12328 ( exit $ac_status )
12329 sv_cv_fault_posix=no
12331 rm -rf conftest.dSYM
12332 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12338 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_posix" >&5
12339 $as_echo "$sv_cv_fault_posix" >&6; }
12346 { $as_echo "$as_me:$LINENO: checking whether a fault handler according to Linux/i386 works" >&5
12347 $as_echo_n "checking whether a fault handler according to Linux/i386 works... " >&6; }
12348 if test "${sv_cv_fault_linux_i386+set}" = set; then
12349 $as_echo_n "(cached) " >&6
12350 else
12352 if test "$cross_compiling" = yes; then
12353 case "$host" in
12354 i?86-*-linux2.[2-9]*) sv_cv_fault_linux_i386=yes ;;
12356 cat >conftest.$ac_ext <<_ACEOF
12358 /* confdefs.h. */
12359 _ACEOF
12360 cat confdefs.h >>conftest.$ac_ext
12361 cat >>conftest.$ac_ext <<_ACEOF
12362 /* end confdefs.h. */
12364 #include <signal.h>
12365 #include <asm/sigcontext.h>
12366 void sigsegv_handler (int sig, struct sigcontext sc)
12368 void *fault_address = (void *) (sc.cr2);
12372 main ()
12374 struct sigaction action;
12377 return 0;
12379 _ACEOF
12380 rm -f conftest.$ac_objext conftest$ac_exeext
12381 if { (ac_try="$ac_link"
12382 case "(($ac_try" in
12383 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12384 *) ac_try_echo=$ac_try;;
12385 esac
12386 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12387 $as_echo "$ac_try_echo") >&5
12388 (eval "$ac_link") 2>conftest.er1
12389 ac_status=$?
12390 grep -v '^ *+' conftest.er1 >conftest.err
12391 rm -f conftest.er1
12392 cat conftest.err >&5
12393 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12394 (exit $ac_status); } && {
12395 test -z "$ac_c_werror_flag" ||
12396 test ! -s conftest.err
12397 } && test -s conftest$ac_exeext && {
12398 test "$cross_compiling" = yes ||
12399 $as_test_x conftest$ac_exeext
12400 }; then
12401 sv_cv_fault_linux_i386="guessing no"
12402 else
12403 $as_echo "$as_me: failed program was:" >&5
12404 sed 's/^/| /' conftest.$ac_ext >&5
12406 sv_cv_fault_linux_i386=no
12409 rm -rf conftest.dSYM
12410 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12411 conftest$ac_exeext conftest.$ac_ext
12413 esac
12415 else
12416 cat >conftest.$ac_ext <<_ACEOF
12418 /* confdefs.h. */
12419 _ACEOF
12420 cat confdefs.h >>conftest.$ac_ext
12421 cat >>conftest.$ac_ext <<_ACEOF
12422 /* end confdefs.h. */
12424 #include <stdlib.h>
12425 #include <signal.h>
12426 #if HAVE_SYS_SIGNAL_H
12427 # include <sys/signal.h>
12428 #endif
12429 #include <asm/sigcontext.h>
12430 #include <sys/types.h>
12431 #include <sys/mman.h>
12432 #if HAVE_MMAP_DEVZERO
12433 # include <fcntl.h>
12434 # ifndef MAP_FILE
12435 # define MAP_FILE 0
12436 # endif
12437 #endif
12438 #ifndef PROT_NONE
12439 # define PROT_NONE 0
12440 #endif
12441 #if HAVE_MMAP_ANON
12442 # define zero_fd -1
12443 # define map_flags MAP_ANON | MAP_PRIVATE
12444 #elif HAVE_MMAP_ANONYMOUS
12445 # define zero_fd -1
12446 # define map_flags MAP_ANONYMOUS | MAP_PRIVATE
12447 #elif HAVE_MMAP_DEVZERO
12448 static int zero_fd;
12449 # define map_flags MAP_FILE | MAP_PRIVATE
12450 #endif
12451 unsigned long page;
12452 int handler_called = 0;
12453 void sigsegv_handler (int sig, struct sigcontext sc)
12455 void *fault_address = (void *) (sc.cr2);
12456 handler_called++;
12457 if (handler_called == 10)
12458 exit (4);
12459 if (fault_address != (void*)(page + 0x678))
12460 exit (3);
12461 if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
12462 exit (2);
12464 void crasher (unsigned long p)
12466 *(int *) (p + 0x678) = 42;
12468 int main ()
12470 void *p;
12471 struct sigaction action;
12472 /* Preparations. */
12473 #if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
12474 zero_fd = open ("/dev/zero", O_RDONLY, 0644);
12475 #endif
12476 /* Setup some mmaped memory. */
12477 #ifdef __hpux
12478 /* HP-UX 10 mmap() often fails when given a hint. So give the OS complete
12479 freedom about the address range. */
12480 p = mmap ((void *) 0, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
12481 #else
12482 p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
12483 #endif
12484 if (p == (void *)(-1))
12485 exit (2);
12486 page = (unsigned long) p;
12487 /* Make it read-only. */
12488 if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
12489 exit (2);
12490 /* Install the SIGSEGV handler. */
12491 sigemptyset(&action.sa_mask);
12493 action.sa_handler = (void (*) (int)) &sigsegv_handler;
12494 action.sa_flags = 0;
12496 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
12497 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
12498 /* The first write access should invoke the handler and then complete. */
12499 crasher (page);
12500 /* The second write access should not invoke the handler. */
12501 crasher (page);
12502 /* Check that the handler was called only once. */
12503 if (handler_called != 1)
12504 exit (1);
12505 /* Test passed! */
12506 return 0;
12508 _ACEOF
12509 rm -f conftest$ac_exeext
12510 if { (ac_try="$ac_link"
12511 case "(($ac_try" in
12512 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12513 *) ac_try_echo=$ac_try;;
12514 esac
12515 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12516 $as_echo "$ac_try_echo") >&5
12517 (eval "$ac_link") 2>&5
12518 ac_status=$?
12519 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12520 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12521 { (case "(($ac_try" in
12522 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12523 *) ac_try_echo=$ac_try;;
12524 esac
12525 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12526 $as_echo "$ac_try_echo") >&5
12527 (eval "$ac_try") 2>&5
12528 ac_status=$?
12529 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12530 (exit $ac_status); }; }; then
12531 sv_cv_fault_linux_i386=yes
12532 else
12533 $as_echo "$as_me: program exited with status $ac_status" >&5
12534 $as_echo "$as_me: failed program was:" >&5
12535 sed 's/^/| /' conftest.$ac_ext >&5
12537 ( exit $ac_status )
12538 sv_cv_fault_linux_i386=no
12540 rm -rf conftest.dSYM
12541 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12547 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_linux_i386" >&5
12548 $as_echo "$sv_cv_fault_linux_i386" >&6; }
12555 { $as_echo "$as_me:$LINENO: checking whether a fault handler according to old Linux/i386 works" >&5
12556 $as_echo_n "checking whether a fault handler according to old Linux/i386 works... " >&6; }
12557 if test "${sv_cv_fault_linux_i386_old+set}" = set; then
12558 $as_echo_n "(cached) " >&6
12559 else
12561 if test "$cross_compiling" = yes; then
12562 case "$host" in
12563 i?86-*-linux2.[2-9]*) sv_cv_fault_linux_i386_old=yes ;;
12565 cat >conftest.$ac_ext <<_ACEOF
12567 /* confdefs.h. */
12568 _ACEOF
12569 cat confdefs.h >>conftest.$ac_ext
12570 cat >>conftest.$ac_ext <<_ACEOF
12571 /* end confdefs.h. */
12573 #include <signal.h>
12575 void sigsegv_handler (int sig, unsigned int more)
12577 void *fault_address = (void *) (((unsigned long *) &more) [21]);
12581 main ()
12583 struct sigaction action;
12586 return 0;
12588 _ACEOF
12589 rm -f conftest.$ac_objext conftest$ac_exeext
12590 if { (ac_try="$ac_link"
12591 case "(($ac_try" in
12592 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12593 *) ac_try_echo=$ac_try;;
12594 esac
12595 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12596 $as_echo "$ac_try_echo") >&5
12597 (eval "$ac_link") 2>conftest.er1
12598 ac_status=$?
12599 grep -v '^ *+' conftest.er1 >conftest.err
12600 rm -f conftest.er1
12601 cat conftest.err >&5
12602 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12603 (exit $ac_status); } && {
12604 test -z "$ac_c_werror_flag" ||
12605 test ! -s conftest.err
12606 } && test -s conftest$ac_exeext && {
12607 test "$cross_compiling" = yes ||
12608 $as_test_x conftest$ac_exeext
12609 }; then
12610 sv_cv_fault_linux_i386_old="guessing no"
12611 else
12612 $as_echo "$as_me: failed program was:" >&5
12613 sed 's/^/| /' conftest.$ac_ext >&5
12615 sv_cv_fault_linux_i386_old=no
12618 rm -rf conftest.dSYM
12619 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12620 conftest$ac_exeext conftest.$ac_ext
12622 esac
12624 else
12625 cat >conftest.$ac_ext <<_ACEOF
12627 /* confdefs.h. */
12628 _ACEOF
12629 cat confdefs.h >>conftest.$ac_ext
12630 cat >>conftest.$ac_ext <<_ACEOF
12631 /* end confdefs.h. */
12633 #include <stdlib.h>
12634 #include <signal.h>
12635 #if HAVE_SYS_SIGNAL_H
12636 # include <sys/signal.h>
12637 #endif
12639 #include <sys/types.h>
12640 #include <sys/mman.h>
12641 #if HAVE_MMAP_DEVZERO
12642 # include <fcntl.h>
12643 # ifndef MAP_FILE
12644 # define MAP_FILE 0
12645 # endif
12646 #endif
12647 #ifndef PROT_NONE
12648 # define PROT_NONE 0
12649 #endif
12650 #if HAVE_MMAP_ANON
12651 # define zero_fd -1
12652 # define map_flags MAP_ANON | MAP_PRIVATE
12653 #elif HAVE_MMAP_ANONYMOUS
12654 # define zero_fd -1
12655 # define map_flags MAP_ANONYMOUS | MAP_PRIVATE
12656 #elif HAVE_MMAP_DEVZERO
12657 static int zero_fd;
12658 # define map_flags MAP_FILE | MAP_PRIVATE
12659 #endif
12660 unsigned long page;
12661 int handler_called = 0;
12662 void sigsegv_handler (int sig, unsigned int more)
12664 void *fault_address = (void *) (((unsigned long *) &more) [21]);
12665 handler_called++;
12666 if (handler_called == 10)
12667 exit (4);
12668 if (fault_address != (void*)(page + 0x678))
12669 exit (3);
12670 if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
12671 exit (2);
12673 void crasher (unsigned long p)
12675 *(int *) (p + 0x678) = 42;
12677 int main ()
12679 void *p;
12680 struct sigaction action;
12681 /* Preparations. */
12682 #if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
12683 zero_fd = open ("/dev/zero", O_RDONLY, 0644);
12684 #endif
12685 /* Setup some mmaped memory. */
12686 #ifdef __hpux
12687 /* HP-UX 10 mmap() often fails when given a hint. So give the OS complete
12688 freedom about the address range. */
12689 p = mmap ((void *) 0, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
12690 #else
12691 p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
12692 #endif
12693 if (p == (void *)(-1))
12694 exit (2);
12695 page = (unsigned long) p;
12696 /* Make it read-only. */
12697 if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
12698 exit (2);
12699 /* Install the SIGSEGV handler. */
12700 sigemptyset(&action.sa_mask);
12702 action.sa_handler = (void (*) (int)) &sigsegv_handler;
12703 action.sa_flags = 0;
12705 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
12706 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
12707 /* The first write access should invoke the handler and then complete. */
12708 crasher (page);
12709 /* The second write access should not invoke the handler. */
12710 crasher (page);
12711 /* Check that the handler was called only once. */
12712 if (handler_called != 1)
12713 exit (1);
12714 /* Test passed! */
12715 return 0;
12717 _ACEOF
12718 rm -f conftest$ac_exeext
12719 if { (ac_try="$ac_link"
12720 case "(($ac_try" in
12721 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12722 *) ac_try_echo=$ac_try;;
12723 esac
12724 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12725 $as_echo "$ac_try_echo") >&5
12726 (eval "$ac_link") 2>&5
12727 ac_status=$?
12728 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12729 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12730 { (case "(($ac_try" in
12731 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12732 *) ac_try_echo=$ac_try;;
12733 esac
12734 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12735 $as_echo "$ac_try_echo") >&5
12736 (eval "$ac_try") 2>&5
12737 ac_status=$?
12738 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12739 (exit $ac_status); }; }; then
12740 sv_cv_fault_linux_i386_old=yes
12741 else
12742 $as_echo "$as_me: program exited with status $ac_status" >&5
12743 $as_echo "$as_me: failed program was:" >&5
12744 sed 's/^/| /' conftest.$ac_ext >&5
12746 ( exit $ac_status )
12747 sv_cv_fault_linux_i386_old=no
12749 rm -rf conftest.dSYM
12750 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12756 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_linux_i386_old" >&5
12757 $as_echo "$sv_cv_fault_linux_i386_old" >&6; }
12764 { $as_echo "$as_me:$LINENO: checking whether a fault handler according to Linux/m68k works" >&5
12765 $as_echo_n "checking whether a fault handler according to Linux/m68k works... " >&6; }
12766 if test "${sv_cv_fault_linux_m68k+set}" = set; then
12767 $as_echo_n "(cached) " >&6
12768 else
12770 if test "$cross_compiling" = yes; then
12771 case "$host" in
12774 cat >conftest.$ac_ext <<_ACEOF
12776 /* confdefs.h. */
12777 _ACEOF
12778 cat confdefs.h >>conftest.$ac_ext
12779 cat >>conftest.$ac_ext <<_ACEOF
12780 /* end confdefs.h. */
12782 #include <signal.h>
12783 #include <asm/sigcontext.h>
12784 #include "$srcdir/src/fault-linux-m68k.c"
12785 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
12787 void *fault_address = (void *) (get_fault_addr (scp));
12791 main ()
12793 struct sigaction action;
12796 return 0;
12798 _ACEOF
12799 rm -f conftest.$ac_objext conftest$ac_exeext
12800 if { (ac_try="$ac_link"
12801 case "(($ac_try" in
12802 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12803 *) ac_try_echo=$ac_try;;
12804 esac
12805 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12806 $as_echo "$ac_try_echo") >&5
12807 (eval "$ac_link") 2>conftest.er1
12808 ac_status=$?
12809 grep -v '^ *+' conftest.er1 >conftest.err
12810 rm -f conftest.er1
12811 cat conftest.err >&5
12812 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12813 (exit $ac_status); } && {
12814 test -z "$ac_c_werror_flag" ||
12815 test ! -s conftest.err
12816 } && test -s conftest$ac_exeext && {
12817 test "$cross_compiling" = yes ||
12818 $as_test_x conftest$ac_exeext
12819 }; then
12820 sv_cv_fault_linux_m68k="guessing no"
12821 else
12822 $as_echo "$as_me: failed program was:" >&5
12823 sed 's/^/| /' conftest.$ac_ext >&5
12825 sv_cv_fault_linux_m68k=no
12828 rm -rf conftest.dSYM
12829 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12830 conftest$ac_exeext conftest.$ac_ext
12832 esac
12834 else
12835 cat >conftest.$ac_ext <<_ACEOF
12837 /* confdefs.h. */
12838 _ACEOF
12839 cat confdefs.h >>conftest.$ac_ext
12840 cat >>conftest.$ac_ext <<_ACEOF
12841 /* end confdefs.h. */
12843 #include <stdlib.h>
12844 #include <signal.h>
12845 #if HAVE_SYS_SIGNAL_H
12846 # include <sys/signal.h>
12847 #endif
12848 #include <asm/sigcontext.h>
12849 #include "$srcdir/src/fault-linux-m68k.c"
12850 #include <sys/types.h>
12851 #include <sys/mman.h>
12852 #if HAVE_MMAP_DEVZERO
12853 # include <fcntl.h>
12854 # ifndef MAP_FILE
12855 # define MAP_FILE 0
12856 # endif
12857 #endif
12858 #ifndef PROT_NONE
12859 # define PROT_NONE 0
12860 #endif
12861 #if HAVE_MMAP_ANON
12862 # define zero_fd -1
12863 # define map_flags MAP_ANON | MAP_PRIVATE
12864 #elif HAVE_MMAP_ANONYMOUS
12865 # define zero_fd -1
12866 # define map_flags MAP_ANONYMOUS | MAP_PRIVATE
12867 #elif HAVE_MMAP_DEVZERO
12868 static int zero_fd;
12869 # define map_flags MAP_FILE | MAP_PRIVATE
12870 #endif
12871 unsigned long page;
12872 int handler_called = 0;
12873 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
12875 void *fault_address = (void *) (get_fault_addr (scp));
12876 handler_called++;
12877 if (handler_called == 10)
12878 exit (4);
12879 if (fault_address != (void*)(page + 0x678))
12880 exit (3);
12881 if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
12882 exit (2);
12884 void crasher (unsigned long p)
12886 *(int *) (p + 0x678) = 42;
12888 int main ()
12890 void *p;
12891 struct sigaction action;
12892 /* Preparations. */
12893 #if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
12894 zero_fd = open ("/dev/zero", O_RDONLY, 0644);
12895 #endif
12896 /* Setup some mmaped memory. */
12897 #ifdef __hpux
12898 /* HP-UX 10 mmap() often fails when given a hint. So give the OS complete
12899 freedom about the address range. */
12900 p = mmap ((void *) 0, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
12901 #else
12902 p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
12903 #endif
12904 if (p == (void *)(-1))
12905 exit (2);
12906 page = (unsigned long) p;
12907 /* Make it read-only. */
12908 if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
12909 exit (2);
12910 /* Install the SIGSEGV handler. */
12911 sigemptyset(&action.sa_mask);
12913 action.sa_handler = (void (*) (int)) &sigsegv_handler;
12914 action.sa_flags = 0;
12916 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
12917 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
12918 /* The first write access should invoke the handler and then complete. */
12919 crasher (page);
12920 /* The second write access should not invoke the handler. */
12921 crasher (page);
12922 /* Check that the handler was called only once. */
12923 if (handler_called != 1)
12924 exit (1);
12925 /* Test passed! */
12926 return 0;
12928 _ACEOF
12929 rm -f conftest$ac_exeext
12930 if { (ac_try="$ac_link"
12931 case "(($ac_try" in
12932 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12933 *) ac_try_echo=$ac_try;;
12934 esac
12935 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12936 $as_echo "$ac_try_echo") >&5
12937 (eval "$ac_link") 2>&5
12938 ac_status=$?
12939 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12940 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12941 { (case "(($ac_try" in
12942 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12943 *) ac_try_echo=$ac_try;;
12944 esac
12945 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12946 $as_echo "$ac_try_echo") >&5
12947 (eval "$ac_try") 2>&5
12948 ac_status=$?
12949 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12950 (exit $ac_status); }; }; then
12951 sv_cv_fault_linux_m68k=yes
12952 else
12953 $as_echo "$as_me: program exited with status $ac_status" >&5
12954 $as_echo "$as_me: failed program was:" >&5
12955 sed 's/^/| /' conftest.$ac_ext >&5
12957 ( exit $ac_status )
12958 sv_cv_fault_linux_m68k=no
12960 rm -rf conftest.dSYM
12961 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12967 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_linux_m68k" >&5
12968 $as_echo "$sv_cv_fault_linux_m68k" >&6; }
12975 { $as_echo "$as_me:$LINENO: checking whether a fault handler according to Linux/PowerPC works" >&5
12976 $as_echo_n "checking whether a fault handler according to Linux/PowerPC works... " >&6; }
12977 if test "${sv_cv_fault_linux_powerpc+set}" = set; then
12978 $as_echo_n "(cached) " >&6
12979 else
12981 if test "$cross_compiling" = yes; then
12982 case "$host" in
12985 cat >conftest.$ac_ext <<_ACEOF
12987 /* confdefs.h. */
12988 _ACEOF
12989 cat confdefs.h >>conftest.$ac_ext
12990 cat >>conftest.$ac_ext <<_ACEOF
12991 /* end confdefs.h. */
12993 #include <signal.h>
12994 #include <asm/sigcontext.h>
12995 void sigsegv_handler (int sig, struct sigcontext *scp)
12997 void *fault_address = (void *) (scp->regs->dar);
13001 main ()
13003 struct sigaction action;
13006 return 0;
13008 _ACEOF
13009 rm -f conftest.$ac_objext conftest$ac_exeext
13010 if { (ac_try="$ac_link"
13011 case "(($ac_try" in
13012 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13013 *) ac_try_echo=$ac_try;;
13014 esac
13015 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13016 $as_echo "$ac_try_echo") >&5
13017 (eval "$ac_link") 2>conftest.er1
13018 ac_status=$?
13019 grep -v '^ *+' conftest.er1 >conftest.err
13020 rm -f conftest.er1
13021 cat conftest.err >&5
13022 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13023 (exit $ac_status); } && {
13024 test -z "$ac_c_werror_flag" ||
13025 test ! -s conftest.err
13026 } && test -s conftest$ac_exeext && {
13027 test "$cross_compiling" = yes ||
13028 $as_test_x conftest$ac_exeext
13029 }; then
13030 sv_cv_fault_linux_powerpc="guessing no"
13031 else
13032 $as_echo "$as_me: failed program was:" >&5
13033 sed 's/^/| /' conftest.$ac_ext >&5
13035 sv_cv_fault_linux_powerpc=no
13038 rm -rf conftest.dSYM
13039 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13040 conftest$ac_exeext conftest.$ac_ext
13042 esac
13044 else
13045 cat >conftest.$ac_ext <<_ACEOF
13047 /* confdefs.h. */
13048 _ACEOF
13049 cat confdefs.h >>conftest.$ac_ext
13050 cat >>conftest.$ac_ext <<_ACEOF
13051 /* end confdefs.h. */
13053 #include <stdlib.h>
13054 #include <signal.h>
13055 #if HAVE_SYS_SIGNAL_H
13056 # include <sys/signal.h>
13057 #endif
13058 #include <asm/sigcontext.h>
13059 #include <sys/types.h>
13060 #include <sys/mman.h>
13061 #if HAVE_MMAP_DEVZERO
13062 # include <fcntl.h>
13063 # ifndef MAP_FILE
13064 # define MAP_FILE 0
13065 # endif
13066 #endif
13067 #ifndef PROT_NONE
13068 # define PROT_NONE 0
13069 #endif
13070 #if HAVE_MMAP_ANON
13071 # define zero_fd -1
13072 # define map_flags MAP_ANON | MAP_PRIVATE
13073 #elif HAVE_MMAP_ANONYMOUS
13074 # define zero_fd -1
13075 # define map_flags MAP_ANONYMOUS | MAP_PRIVATE
13076 #elif HAVE_MMAP_DEVZERO
13077 static int zero_fd;
13078 # define map_flags MAP_FILE | MAP_PRIVATE
13079 #endif
13080 unsigned long page;
13081 int handler_called = 0;
13082 void sigsegv_handler (int sig, struct sigcontext *scp)
13084 void *fault_address = (void *) (scp->regs->dar);
13085 handler_called++;
13086 if (handler_called == 10)
13087 exit (4);
13088 if (fault_address != (void*)(page + 0x678))
13089 exit (3);
13090 if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
13091 exit (2);
13093 void crasher (unsigned long p)
13095 *(int *) (p + 0x678) = 42;
13097 int main ()
13099 void *p;
13100 struct sigaction action;
13101 /* Preparations. */
13102 #if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
13103 zero_fd = open ("/dev/zero", O_RDONLY, 0644);
13104 #endif
13105 /* Setup some mmaped memory. */
13106 #ifdef __hpux
13107 /* HP-UX 10 mmap() often fails when given a hint. So give the OS complete
13108 freedom about the address range. */
13109 p = mmap ((void *) 0, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
13110 #else
13111 p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
13112 #endif
13113 if (p == (void *)(-1))
13114 exit (2);
13115 page = (unsigned long) p;
13116 /* Make it read-only. */
13117 if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
13118 exit (2);
13119 /* Install the SIGSEGV handler. */
13120 sigemptyset(&action.sa_mask);
13122 action.sa_handler = (void (*) (int)) &sigsegv_handler;
13123 action.sa_flags = 0;
13125 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
13126 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
13127 /* The first write access should invoke the handler and then complete. */
13128 crasher (page);
13129 /* The second write access should not invoke the handler. */
13130 crasher (page);
13131 /* Check that the handler was called only once. */
13132 if (handler_called != 1)
13133 exit (1);
13134 /* Test passed! */
13135 return 0;
13137 _ACEOF
13138 rm -f conftest$ac_exeext
13139 if { (ac_try="$ac_link"
13140 case "(($ac_try" in
13141 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13142 *) ac_try_echo=$ac_try;;
13143 esac
13144 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13145 $as_echo "$ac_try_echo") >&5
13146 (eval "$ac_link") 2>&5
13147 ac_status=$?
13148 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13149 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13150 { (case "(($ac_try" in
13151 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13152 *) ac_try_echo=$ac_try;;
13153 esac
13154 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13155 $as_echo "$ac_try_echo") >&5
13156 (eval "$ac_try") 2>&5
13157 ac_status=$?
13158 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13159 (exit $ac_status); }; }; then
13160 sv_cv_fault_linux_powerpc=yes
13161 else
13162 $as_echo "$as_me: program exited with status $ac_status" >&5
13163 $as_echo "$as_me: failed program was:" >&5
13164 sed 's/^/| /' conftest.$ac_ext >&5
13166 ( exit $ac_status )
13167 sv_cv_fault_linux_powerpc=no
13169 rm -rf conftest.dSYM
13170 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13176 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_linux_powerpc" >&5
13177 $as_echo "$sv_cv_fault_linux_powerpc" >&6; }
13184 { $as_echo "$as_me:$LINENO: checking whether a fault handler according to Linux/HPPA works" >&5
13185 $as_echo_n "checking whether a fault handler according to Linux/HPPA works... " >&6; }
13186 if test "${sv_cv_fault_linux_hppa+set}" = set; then
13187 $as_echo_n "(cached) " >&6
13188 else
13190 if test "$cross_compiling" = yes; then
13191 case "$host" in
13194 cat >conftest.$ac_ext <<_ACEOF
13196 /* confdefs.h. */
13197 _ACEOF
13198 cat confdefs.h >>conftest.$ac_ext
13199 cat >>conftest.$ac_ext <<_ACEOF
13200 /* end confdefs.h. */
13202 #include <signal.h>
13204 void sigsegv_handler (int sig, siginfo_t *sip, void *ucp)
13206 void *fault_address = (void *) (sip->si_ptr);
13210 main ()
13212 struct sigaction action;
13213 action.sa_sigaction = &sigsegv_handler;
13214 action.sa_flags = SA_SIGINFO;
13216 return 0;
13218 _ACEOF
13219 rm -f conftest.$ac_objext conftest$ac_exeext
13220 if { (ac_try="$ac_link"
13221 case "(($ac_try" in
13222 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13223 *) ac_try_echo=$ac_try;;
13224 esac
13225 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13226 $as_echo "$ac_try_echo") >&5
13227 (eval "$ac_link") 2>conftest.er1
13228 ac_status=$?
13229 grep -v '^ *+' conftest.er1 >conftest.err
13230 rm -f conftest.er1
13231 cat conftest.err >&5
13232 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13233 (exit $ac_status); } && {
13234 test -z "$ac_c_werror_flag" ||
13235 test ! -s conftest.err
13236 } && test -s conftest$ac_exeext && {
13237 test "$cross_compiling" = yes ||
13238 $as_test_x conftest$ac_exeext
13239 }; then
13240 sv_cv_fault_linux_hppa="guessing no"
13241 else
13242 $as_echo "$as_me: failed program was:" >&5
13243 sed 's/^/| /' conftest.$ac_ext >&5
13245 sv_cv_fault_linux_hppa=no
13248 rm -rf conftest.dSYM
13249 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13250 conftest$ac_exeext conftest.$ac_ext
13252 esac
13254 else
13255 cat >conftest.$ac_ext <<_ACEOF
13257 /* confdefs.h. */
13258 _ACEOF
13259 cat confdefs.h >>conftest.$ac_ext
13260 cat >>conftest.$ac_ext <<_ACEOF
13261 /* end confdefs.h. */
13263 #include <stdlib.h>
13264 #include <signal.h>
13265 #if HAVE_SYS_SIGNAL_H
13266 # include <sys/signal.h>
13267 #endif
13269 #include <sys/types.h>
13270 #include <sys/mman.h>
13271 #if HAVE_MMAP_DEVZERO
13272 # include <fcntl.h>
13273 # ifndef MAP_FILE
13274 # define MAP_FILE 0
13275 # endif
13276 #endif
13277 #ifndef PROT_NONE
13278 # define PROT_NONE 0
13279 #endif
13280 #if HAVE_MMAP_ANON
13281 # define zero_fd -1
13282 # define map_flags MAP_ANON | MAP_PRIVATE
13283 #elif HAVE_MMAP_ANONYMOUS
13284 # define zero_fd -1
13285 # define map_flags MAP_ANONYMOUS | MAP_PRIVATE
13286 #elif HAVE_MMAP_DEVZERO
13287 static int zero_fd;
13288 # define map_flags MAP_FILE | MAP_PRIVATE
13289 #endif
13290 unsigned long page;
13291 int handler_called = 0;
13292 void sigsegv_handler (int sig, siginfo_t *sip, void *ucp)
13294 void *fault_address = (void *) (sip->si_ptr);
13295 handler_called++;
13296 if (handler_called == 10)
13297 exit (4);
13298 if (fault_address != (void*)(page + 0x678))
13299 exit (3);
13300 if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
13301 exit (2);
13303 void crasher (unsigned long p)
13305 *(int *) (p + 0x678) = 42;
13307 int main ()
13309 void *p;
13310 struct sigaction action;
13311 /* Preparations. */
13312 #if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
13313 zero_fd = open ("/dev/zero", O_RDONLY, 0644);
13314 #endif
13315 /* Setup some mmaped memory. */
13316 #ifdef __hpux
13317 /* HP-UX 10 mmap() often fails when given a hint. So give the OS complete
13318 freedom about the address range. */
13319 p = mmap ((void *) 0, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
13320 #else
13321 p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
13322 #endif
13323 if (p == (void *)(-1))
13324 exit (2);
13325 page = (unsigned long) p;
13326 /* Make it read-only. */
13327 if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
13328 exit (2);
13329 /* Install the SIGSEGV handler. */
13330 sigemptyset(&action.sa_mask);
13331 action.sa_sigaction = &sigsegv_handler;
13332 action.sa_flags = SA_SIGINFO;
13333 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
13334 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
13335 /* The first write access should invoke the handler and then complete. */
13336 crasher (page);
13337 /* The second write access should not invoke the handler. */
13338 crasher (page);
13339 /* Check that the handler was called only once. */
13340 if (handler_called != 1)
13341 exit (1);
13342 /* Test passed! */
13343 return 0;
13345 _ACEOF
13346 rm -f conftest$ac_exeext
13347 if { (ac_try="$ac_link"
13348 case "(($ac_try" in
13349 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13350 *) ac_try_echo=$ac_try;;
13351 esac
13352 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13353 $as_echo "$ac_try_echo") >&5
13354 (eval "$ac_link") 2>&5
13355 ac_status=$?
13356 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13357 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13358 { (case "(($ac_try" in
13359 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13360 *) ac_try_echo=$ac_try;;
13361 esac
13362 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13363 $as_echo "$ac_try_echo") >&5
13364 (eval "$ac_try") 2>&5
13365 ac_status=$?
13366 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13367 (exit $ac_status); }; }; then
13368 sv_cv_fault_linux_hppa=yes
13369 else
13370 $as_echo "$as_me: program exited with status $ac_status" >&5
13371 $as_echo "$as_me: failed program was:" >&5
13372 sed 's/^/| /' conftest.$ac_ext >&5
13374 ( exit $ac_status )
13375 sv_cv_fault_linux_hppa=no
13377 rm -rf conftest.dSYM
13378 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13384 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_linux_hppa" >&5
13385 $as_echo "$sv_cv_fault_linux_hppa" >&6; }
13392 { $as_echo "$as_me:$LINENO: checking whether a fault handler according to BSD works" >&5
13393 $as_echo_n "checking whether a fault handler according to BSD works... " >&6; }
13394 if test "${sv_cv_fault_bsd+set}" = set; then
13395 $as_echo_n "(cached) " >&6
13396 else
13398 if test "$cross_compiling" = yes; then
13399 case "$host" in
13400 i?86-*-freebsd[4-9]*) sv_cv_fault_bsd=yes ;;
13402 cat >conftest.$ac_ext <<_ACEOF
13404 /* confdefs.h. */
13405 _ACEOF
13406 cat confdefs.h >>conftest.$ac_ext
13407 cat >>conftest.$ac_ext <<_ACEOF
13408 /* end confdefs.h. */
13410 #include <signal.h>
13412 void sigsegv_handler (int sig, int code, struct sigcontext *scp, void *addr)
13414 void *fault_address = (void *) (addr);
13418 main ()
13420 struct sigaction action;
13423 return 0;
13425 _ACEOF
13426 rm -f conftest.$ac_objext conftest$ac_exeext
13427 if { (ac_try="$ac_link"
13428 case "(($ac_try" in
13429 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13430 *) ac_try_echo=$ac_try;;
13431 esac
13432 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13433 $as_echo "$ac_try_echo") >&5
13434 (eval "$ac_link") 2>conftest.er1
13435 ac_status=$?
13436 grep -v '^ *+' conftest.er1 >conftest.err
13437 rm -f conftest.er1
13438 cat conftest.err >&5
13439 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13440 (exit $ac_status); } && {
13441 test -z "$ac_c_werror_flag" ||
13442 test ! -s conftest.err
13443 } && test -s conftest$ac_exeext && {
13444 test "$cross_compiling" = yes ||
13445 $as_test_x conftest$ac_exeext
13446 }; then
13447 sv_cv_fault_bsd="guessing no"
13448 else
13449 $as_echo "$as_me: failed program was:" >&5
13450 sed 's/^/| /' conftest.$ac_ext >&5
13452 sv_cv_fault_bsd=no
13455 rm -rf conftest.dSYM
13456 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13457 conftest$ac_exeext conftest.$ac_ext
13459 esac
13461 else
13462 cat >conftest.$ac_ext <<_ACEOF
13464 /* confdefs.h. */
13465 _ACEOF
13466 cat confdefs.h >>conftest.$ac_ext
13467 cat >>conftest.$ac_ext <<_ACEOF
13468 /* end confdefs.h. */
13470 #include <stdlib.h>
13471 #include <signal.h>
13472 #if HAVE_SYS_SIGNAL_H
13473 # include <sys/signal.h>
13474 #endif
13476 #include <sys/types.h>
13477 #include <sys/mman.h>
13478 #if HAVE_MMAP_DEVZERO
13479 # include <fcntl.h>
13480 # ifndef MAP_FILE
13481 # define MAP_FILE 0
13482 # endif
13483 #endif
13484 #ifndef PROT_NONE
13485 # define PROT_NONE 0
13486 #endif
13487 #if HAVE_MMAP_ANON
13488 # define zero_fd -1
13489 # define map_flags MAP_ANON | MAP_PRIVATE
13490 #elif HAVE_MMAP_ANONYMOUS
13491 # define zero_fd -1
13492 # define map_flags MAP_ANONYMOUS | MAP_PRIVATE
13493 #elif HAVE_MMAP_DEVZERO
13494 static int zero_fd;
13495 # define map_flags MAP_FILE | MAP_PRIVATE
13496 #endif
13497 unsigned long page;
13498 int handler_called = 0;
13499 void sigsegv_handler (int sig, int code, struct sigcontext *scp, void *addr)
13501 void *fault_address = (void *) (addr);
13502 handler_called++;
13503 if (handler_called == 10)
13504 exit (4);
13505 if (fault_address != (void*)(page + 0x678))
13506 exit (3);
13507 if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
13508 exit (2);
13510 void crasher (unsigned long p)
13512 *(int *) (p + 0x678) = 42;
13514 int main ()
13516 void *p;
13517 struct sigaction action;
13518 /* Preparations. */
13519 #if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
13520 zero_fd = open ("/dev/zero", O_RDONLY, 0644);
13521 #endif
13522 /* Setup some mmaped memory. */
13523 #ifdef __hpux
13524 /* HP-UX 10 mmap() often fails when given a hint. So give the OS complete
13525 freedom about the address range. */
13526 p = mmap ((void *) 0, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
13527 #else
13528 p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
13529 #endif
13530 if (p == (void *)(-1))
13531 exit (2);
13532 page = (unsigned long) p;
13533 /* Make it read-only. */
13534 if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
13535 exit (2);
13536 /* Install the SIGSEGV handler. */
13537 sigemptyset(&action.sa_mask);
13539 action.sa_handler = (void (*) (int)) &sigsegv_handler;
13540 action.sa_flags = 0;
13542 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
13543 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
13544 /* The first write access should invoke the handler and then complete. */
13545 crasher (page);
13546 /* The second write access should not invoke the handler. */
13547 crasher (page);
13548 /* Check that the handler was called only once. */
13549 if (handler_called != 1)
13550 exit (1);
13551 /* Test passed! */
13552 return 0;
13554 _ACEOF
13555 rm -f conftest$ac_exeext
13556 if { (ac_try="$ac_link"
13557 case "(($ac_try" in
13558 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13559 *) ac_try_echo=$ac_try;;
13560 esac
13561 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13562 $as_echo "$ac_try_echo") >&5
13563 (eval "$ac_link") 2>&5
13564 ac_status=$?
13565 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13566 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13567 { (case "(($ac_try" in
13568 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13569 *) ac_try_echo=$ac_try;;
13570 esac
13571 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13572 $as_echo "$ac_try_echo") >&5
13573 (eval "$ac_try") 2>&5
13574 ac_status=$?
13575 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13576 (exit $ac_status); }; }; then
13577 sv_cv_fault_bsd=yes
13578 else
13579 $as_echo "$as_me: program exited with status $ac_status" >&5
13580 $as_echo "$as_me: failed program was:" >&5
13581 sed 's/^/| /' conftest.$ac_ext >&5
13583 ( exit $ac_status )
13584 sv_cv_fault_bsd=no
13586 rm -rf conftest.dSYM
13587 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13593 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_bsd" >&5
13594 $as_echo "$sv_cv_fault_bsd" >&6; }
13601 { $as_echo "$as_me:$LINENO: checking whether a fault handler according to IRIX works" >&5
13602 $as_echo_n "checking whether a fault handler according to IRIX works... " >&6; }
13603 if test "${sv_cv_fault_irix+set}" = set; then
13604 $as_echo_n "(cached) " >&6
13605 else
13607 if test "$cross_compiling" = yes; then
13608 case "$host" in
13609 mips-sgi-irix6*) sv_cv_fault_irix=yes ;;
13611 cat >conftest.$ac_ext <<_ACEOF
13613 /* confdefs.h. */
13614 _ACEOF
13615 cat confdefs.h >>conftest.$ac_ext
13616 cat >>conftest.$ac_ext <<_ACEOF
13617 /* end confdefs.h. */
13619 #include <signal.h>
13621 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
13623 void *fault_address = (void *) ((unsigned long) scp->sc_badvaddr);
13627 main ()
13629 struct sigaction action;
13632 return 0;
13634 _ACEOF
13635 rm -f conftest.$ac_objext conftest$ac_exeext
13636 if { (ac_try="$ac_link"
13637 case "(($ac_try" in
13638 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13639 *) ac_try_echo=$ac_try;;
13640 esac
13641 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13642 $as_echo "$ac_try_echo") >&5
13643 (eval "$ac_link") 2>conftest.er1
13644 ac_status=$?
13645 grep -v '^ *+' conftest.er1 >conftest.err
13646 rm -f conftest.er1
13647 cat conftest.err >&5
13648 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13649 (exit $ac_status); } && {
13650 test -z "$ac_c_werror_flag" ||
13651 test ! -s conftest.err
13652 } && test -s conftest$ac_exeext && {
13653 test "$cross_compiling" = yes ||
13654 $as_test_x conftest$ac_exeext
13655 }; then
13656 sv_cv_fault_irix="guessing no"
13657 else
13658 $as_echo "$as_me: failed program was:" >&5
13659 sed 's/^/| /' conftest.$ac_ext >&5
13661 sv_cv_fault_irix=no
13664 rm -rf conftest.dSYM
13665 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13666 conftest$ac_exeext conftest.$ac_ext
13668 esac
13670 else
13671 cat >conftest.$ac_ext <<_ACEOF
13673 /* confdefs.h. */
13674 _ACEOF
13675 cat confdefs.h >>conftest.$ac_ext
13676 cat >>conftest.$ac_ext <<_ACEOF
13677 /* end confdefs.h. */
13679 #include <stdlib.h>
13680 #include <signal.h>
13681 #if HAVE_SYS_SIGNAL_H
13682 # include <sys/signal.h>
13683 #endif
13685 #include <sys/types.h>
13686 #include <sys/mman.h>
13687 #if HAVE_MMAP_DEVZERO
13688 # include <fcntl.h>
13689 # ifndef MAP_FILE
13690 # define MAP_FILE 0
13691 # endif
13692 #endif
13693 #ifndef PROT_NONE
13694 # define PROT_NONE 0
13695 #endif
13696 #if HAVE_MMAP_ANON
13697 # define zero_fd -1
13698 # define map_flags MAP_ANON | MAP_PRIVATE
13699 #elif HAVE_MMAP_ANONYMOUS
13700 # define zero_fd -1
13701 # define map_flags MAP_ANONYMOUS | MAP_PRIVATE
13702 #elif HAVE_MMAP_DEVZERO
13703 static int zero_fd;
13704 # define map_flags MAP_FILE | MAP_PRIVATE
13705 #endif
13706 unsigned long page;
13707 int handler_called = 0;
13708 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
13710 void *fault_address = (void *) ((unsigned long) scp->sc_badvaddr);
13711 handler_called++;
13712 if (handler_called == 10)
13713 exit (4);
13714 if (fault_address != (void*)(page + 0x678))
13715 exit (3);
13716 if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
13717 exit (2);
13719 void crasher (unsigned long p)
13721 *(int *) (p + 0x678) = 42;
13723 int main ()
13725 void *p;
13726 struct sigaction action;
13727 /* Preparations. */
13728 #if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
13729 zero_fd = open ("/dev/zero", O_RDONLY, 0644);
13730 #endif
13731 /* Setup some mmaped memory. */
13732 #ifdef __hpux
13733 /* HP-UX 10 mmap() often fails when given a hint. So give the OS complete
13734 freedom about the address range. */
13735 p = mmap ((void *) 0, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
13736 #else
13737 p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
13738 #endif
13739 if (p == (void *)(-1))
13740 exit (2);
13741 page = (unsigned long) p;
13742 /* Make it read-only. */
13743 if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
13744 exit (2);
13745 /* Install the SIGSEGV handler. */
13746 sigemptyset(&action.sa_mask);
13748 action.sa_handler = (void (*) (int)) &sigsegv_handler;
13749 action.sa_flags = 0;
13751 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
13752 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
13753 /* The first write access should invoke the handler and then complete. */
13754 crasher (page);
13755 /* The second write access should not invoke the handler. */
13756 crasher (page);
13757 /* Check that the handler was called only once. */
13758 if (handler_called != 1)
13759 exit (1);
13760 /* Test passed! */
13761 return 0;
13763 _ACEOF
13764 rm -f conftest$ac_exeext
13765 if { (ac_try="$ac_link"
13766 case "(($ac_try" in
13767 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13768 *) ac_try_echo=$ac_try;;
13769 esac
13770 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13771 $as_echo "$ac_try_echo") >&5
13772 (eval "$ac_link") 2>&5
13773 ac_status=$?
13774 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13775 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13776 { (case "(($ac_try" in
13777 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13778 *) ac_try_echo=$ac_try;;
13779 esac
13780 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13781 $as_echo "$ac_try_echo") >&5
13782 (eval "$ac_try") 2>&5
13783 ac_status=$?
13784 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13785 (exit $ac_status); }; }; then
13786 sv_cv_fault_irix=yes
13787 else
13788 $as_echo "$as_me: program exited with status $ac_status" >&5
13789 $as_echo "$as_me: failed program was:" >&5
13790 sed 's/^/| /' conftest.$ac_ext >&5
13792 ( exit $ac_status )
13793 sv_cv_fault_irix=no
13795 rm -rf conftest.dSYM
13796 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13802 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_irix" >&5
13803 $as_echo "$sv_cv_fault_irix" >&6; }
13810 { $as_echo "$as_me:$LINENO: checking whether a fault handler according to HP-UX HPPA works" >&5
13811 $as_echo_n "checking whether a fault handler according to HP-UX HPPA works... " >&6; }
13812 if test "${sv_cv_fault_hpux_hppa+set}" = set; then
13813 $as_echo_n "(cached) " >&6
13814 else
13816 if test "$cross_compiling" = yes; then
13817 case "$host" in
13818 hppa*-*-hpux11*) sv_cv_fault_hpux_hppa=yes ;;
13820 cat >conftest.$ac_ext <<_ACEOF
13822 /* confdefs.h. */
13823 _ACEOF
13824 cat confdefs.h >>conftest.$ac_ext
13825 cat >>conftest.$ac_ext <<_ACEOF
13826 /* end confdefs.h. */
13828 #include <signal.h>
13830 #define USE_64BIT_REGS(mc) \
13831 (((mc).ss_flags & SS_WIDEREGS) && ((mc).ss_flags & SS_NARROWISINVALID))
13832 #define GET_CR21(mc) \
13833 (USE_64BIT_REGS(mc) ? (mc).ss_wide.ss_64.ss_cr21 : (mc).ss_narrow.ss_cr21)
13835 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
13837 void *fault_address = (void *) (GET_CR21 (scp->sc_sl.sl_ss));
13841 main ()
13843 struct sigaction action;
13846 return 0;
13848 _ACEOF
13849 rm -f conftest.$ac_objext conftest$ac_exeext
13850 if { (ac_try="$ac_link"
13851 case "(($ac_try" in
13852 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13853 *) ac_try_echo=$ac_try;;
13854 esac
13855 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13856 $as_echo "$ac_try_echo") >&5
13857 (eval "$ac_link") 2>conftest.er1
13858 ac_status=$?
13859 grep -v '^ *+' conftest.er1 >conftest.err
13860 rm -f conftest.er1
13861 cat conftest.err >&5
13862 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13863 (exit $ac_status); } && {
13864 test -z "$ac_c_werror_flag" ||
13865 test ! -s conftest.err
13866 } && test -s conftest$ac_exeext && {
13867 test "$cross_compiling" = yes ||
13868 $as_test_x conftest$ac_exeext
13869 }; then
13870 sv_cv_fault_hpux_hppa="guessing no"
13871 else
13872 $as_echo "$as_me: failed program was:" >&5
13873 sed 's/^/| /' conftest.$ac_ext >&5
13875 sv_cv_fault_hpux_hppa=no
13878 rm -rf conftest.dSYM
13879 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13880 conftest$ac_exeext conftest.$ac_ext
13882 esac
13884 else
13885 cat >conftest.$ac_ext <<_ACEOF
13887 /* confdefs.h. */
13888 _ACEOF
13889 cat confdefs.h >>conftest.$ac_ext
13890 cat >>conftest.$ac_ext <<_ACEOF
13891 /* end confdefs.h. */
13893 #include <stdlib.h>
13894 #include <signal.h>
13895 #if HAVE_SYS_SIGNAL_H
13896 # include <sys/signal.h>
13897 #endif
13899 #define USE_64BIT_REGS(mc) \
13900 (((mc).ss_flags & SS_WIDEREGS) && ((mc).ss_flags & SS_NARROWISINVALID))
13901 #define GET_CR21(mc) \
13902 (USE_64BIT_REGS(mc) ? (mc).ss_wide.ss_64.ss_cr21 : (mc).ss_narrow.ss_cr21)
13904 #include <sys/types.h>
13905 #include <sys/mman.h>
13906 #if HAVE_MMAP_DEVZERO
13907 # include <fcntl.h>
13908 # ifndef MAP_FILE
13909 # define MAP_FILE 0
13910 # endif
13911 #endif
13912 #ifndef PROT_NONE
13913 # define PROT_NONE 0
13914 #endif
13915 #if HAVE_MMAP_ANON
13916 # define zero_fd -1
13917 # define map_flags MAP_ANON | MAP_PRIVATE
13918 #elif HAVE_MMAP_ANONYMOUS
13919 # define zero_fd -1
13920 # define map_flags MAP_ANONYMOUS | MAP_PRIVATE
13921 #elif HAVE_MMAP_DEVZERO
13922 static int zero_fd;
13923 # define map_flags MAP_FILE | MAP_PRIVATE
13924 #endif
13925 unsigned long page;
13926 int handler_called = 0;
13927 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
13929 void *fault_address = (void *) (GET_CR21 (scp->sc_sl.sl_ss));
13930 handler_called++;
13931 if (handler_called == 10)
13932 exit (4);
13933 if (fault_address != (void*)(page + 0x678))
13934 exit (3);
13935 if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
13936 exit (2);
13938 void crasher (unsigned long p)
13940 *(int *) (p + 0x678) = 42;
13942 int main ()
13944 void *p;
13945 struct sigaction action;
13946 /* Preparations. */
13947 #if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
13948 zero_fd = open ("/dev/zero", O_RDONLY, 0644);
13949 #endif
13950 /* Setup some mmaped memory. */
13951 #ifdef __hpux
13952 /* HP-UX 10 mmap() often fails when given a hint. So give the OS complete
13953 freedom about the address range. */
13954 p = mmap ((void *) 0, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
13955 #else
13956 p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
13957 #endif
13958 if (p == (void *)(-1))
13959 exit (2);
13960 page = (unsigned long) p;
13961 /* Make it read-only. */
13962 if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
13963 exit (2);
13964 /* Install the SIGSEGV handler. */
13965 sigemptyset(&action.sa_mask);
13967 action.sa_handler = (void (*) (int)) &sigsegv_handler;
13968 action.sa_flags = 0;
13970 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
13971 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
13972 /* The first write access should invoke the handler and then complete. */
13973 crasher (page);
13974 /* The second write access should not invoke the handler. */
13975 crasher (page);
13976 /* Check that the handler was called only once. */
13977 if (handler_called != 1)
13978 exit (1);
13979 /* Test passed! */
13980 return 0;
13982 _ACEOF
13983 rm -f conftest$ac_exeext
13984 if { (ac_try="$ac_link"
13985 case "(($ac_try" in
13986 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13987 *) ac_try_echo=$ac_try;;
13988 esac
13989 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13990 $as_echo "$ac_try_echo") >&5
13991 (eval "$ac_link") 2>&5
13992 ac_status=$?
13993 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13994 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13995 { (case "(($ac_try" in
13996 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13997 *) ac_try_echo=$ac_try;;
13998 esac
13999 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14000 $as_echo "$ac_try_echo") >&5
14001 (eval "$ac_try") 2>&5
14002 ac_status=$?
14003 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14004 (exit $ac_status); }; }; then
14005 sv_cv_fault_hpux_hppa=yes
14006 else
14007 $as_echo "$as_me: program exited with status $ac_status" >&5
14008 $as_echo "$as_me: failed program was:" >&5
14009 sed 's/^/| /' conftest.$ac_ext >&5
14011 ( exit $ac_status )
14012 sv_cv_fault_hpux_hppa=no
14014 rm -rf conftest.dSYM
14015 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14021 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_hpux_hppa" >&5
14022 $as_echo "$sv_cv_fault_hpux_hppa" >&6; }
14029 { $as_echo "$as_me:$LINENO: checking whether a fault handler according to OSF/1 Alpha works" >&5
14030 $as_echo_n "checking whether a fault handler according to OSF/1 Alpha works... " >&6; }
14031 if test "${sv_cv_fault_osf_alpha+set}" = set; then
14032 $as_echo_n "(cached) " >&6
14033 else
14035 if test "$cross_compiling" = yes; then
14036 case "$host" in
14037 alpha*-*-osf[4-9]* | alpha*-*-linux2.[4-9]*) sv_cv_fault_osf_alpha=yes ;;
14039 cat >conftest.$ac_ext <<_ACEOF
14041 /* confdefs.h. */
14042 _ACEOF
14043 cat confdefs.h >>conftest.$ac_ext
14044 cat >>conftest.$ac_ext <<_ACEOF
14045 /* end confdefs.h. */
14047 #include <signal.h>
14049 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
14051 void *fault_address = (void *) (scp->sc_traparg_a0);
14055 main ()
14057 struct sigaction action;
14060 return 0;
14062 _ACEOF
14063 rm -f conftest.$ac_objext conftest$ac_exeext
14064 if { (ac_try="$ac_link"
14065 case "(($ac_try" in
14066 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14067 *) ac_try_echo=$ac_try;;
14068 esac
14069 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14070 $as_echo "$ac_try_echo") >&5
14071 (eval "$ac_link") 2>conftest.er1
14072 ac_status=$?
14073 grep -v '^ *+' conftest.er1 >conftest.err
14074 rm -f conftest.er1
14075 cat conftest.err >&5
14076 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14077 (exit $ac_status); } && {
14078 test -z "$ac_c_werror_flag" ||
14079 test ! -s conftest.err
14080 } && test -s conftest$ac_exeext && {
14081 test "$cross_compiling" = yes ||
14082 $as_test_x conftest$ac_exeext
14083 }; then
14084 sv_cv_fault_osf_alpha="guessing no"
14085 else
14086 $as_echo "$as_me: failed program was:" >&5
14087 sed 's/^/| /' conftest.$ac_ext >&5
14089 sv_cv_fault_osf_alpha=no
14092 rm -rf conftest.dSYM
14093 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14094 conftest$ac_exeext conftest.$ac_ext
14096 esac
14098 else
14099 cat >conftest.$ac_ext <<_ACEOF
14101 /* confdefs.h. */
14102 _ACEOF
14103 cat confdefs.h >>conftest.$ac_ext
14104 cat >>conftest.$ac_ext <<_ACEOF
14105 /* end confdefs.h. */
14107 #include <stdlib.h>
14108 #include <signal.h>
14109 #if HAVE_SYS_SIGNAL_H
14110 # include <sys/signal.h>
14111 #endif
14113 #include <sys/types.h>
14114 #include <sys/mman.h>
14115 #if HAVE_MMAP_DEVZERO
14116 # include <fcntl.h>
14117 # ifndef MAP_FILE
14118 # define MAP_FILE 0
14119 # endif
14120 #endif
14121 #ifndef PROT_NONE
14122 # define PROT_NONE 0
14123 #endif
14124 #if HAVE_MMAP_ANON
14125 # define zero_fd -1
14126 # define map_flags MAP_ANON | MAP_PRIVATE
14127 #elif HAVE_MMAP_ANONYMOUS
14128 # define zero_fd -1
14129 # define map_flags MAP_ANONYMOUS | MAP_PRIVATE
14130 #elif HAVE_MMAP_DEVZERO
14131 static int zero_fd;
14132 # define map_flags MAP_FILE | MAP_PRIVATE
14133 #endif
14134 unsigned long page;
14135 int handler_called = 0;
14136 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
14138 void *fault_address = (void *) (scp->sc_traparg_a0);
14139 handler_called++;
14140 if (handler_called == 10)
14141 exit (4);
14142 if (fault_address != (void*)(page + 0x678))
14143 exit (3);
14144 if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
14145 exit (2);
14147 void crasher (unsigned long p)
14149 *(int *) (p + 0x678) = 42;
14151 int main ()
14153 void *p;
14154 struct sigaction action;
14155 /* Preparations. */
14156 #if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
14157 zero_fd = open ("/dev/zero", O_RDONLY, 0644);
14158 #endif
14159 /* Setup some mmaped memory. */
14160 #ifdef __hpux
14161 /* HP-UX 10 mmap() often fails when given a hint. So give the OS complete
14162 freedom about the address range. */
14163 p = mmap ((void *) 0, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
14164 #else
14165 p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
14166 #endif
14167 if (p == (void *)(-1))
14168 exit (2);
14169 page = (unsigned long) p;
14170 /* Make it read-only. */
14171 if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
14172 exit (2);
14173 /* Install the SIGSEGV handler. */
14174 sigemptyset(&action.sa_mask);
14176 action.sa_handler = (void (*) (int)) &sigsegv_handler;
14177 action.sa_flags = 0;
14179 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
14180 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
14181 /* The first write access should invoke the handler and then complete. */
14182 crasher (page);
14183 /* The second write access should not invoke the handler. */
14184 crasher (page);
14185 /* Check that the handler was called only once. */
14186 if (handler_called != 1)
14187 exit (1);
14188 /* Test passed! */
14189 return 0;
14191 _ACEOF
14192 rm -f conftest$ac_exeext
14193 if { (ac_try="$ac_link"
14194 case "(($ac_try" in
14195 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14196 *) ac_try_echo=$ac_try;;
14197 esac
14198 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14199 $as_echo "$ac_try_echo") >&5
14200 (eval "$ac_link") 2>&5
14201 ac_status=$?
14202 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14203 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14204 { (case "(($ac_try" in
14205 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14206 *) ac_try_echo=$ac_try;;
14207 esac
14208 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14209 $as_echo "$ac_try_echo") >&5
14210 (eval "$ac_try") 2>&5
14211 ac_status=$?
14212 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14213 (exit $ac_status); }; }; then
14214 sv_cv_fault_osf_alpha=yes
14215 else
14216 $as_echo "$as_me: program exited with status $ac_status" >&5
14217 $as_echo "$as_me: failed program was:" >&5
14218 sed 's/^/| /' conftest.$ac_ext >&5
14220 ( exit $ac_status )
14221 sv_cv_fault_osf_alpha=no
14223 rm -rf conftest.dSYM
14224 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14230 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_osf_alpha" >&5
14231 $as_echo "$sv_cv_fault_osf_alpha" >&6; }
14238 { $as_echo "$as_me:$LINENO: checking whether a fault handler according to NetBSD Alpha works" >&5
14239 $as_echo_n "checking whether a fault handler according to NetBSD Alpha works... " >&6; }
14240 if test "${sv_cv_fault_netbsd_alpha+set}" = set; then
14241 $as_echo_n "(cached) " >&6
14242 else
14244 if test "$cross_compiling" = yes; then
14245 case "$host" in
14246 alpha*-*-osf[4-9]* | alpha-*-*bsd*) sv_cv_fault_netbsd_alpha=yes ;;
14248 cat >conftest.$ac_ext <<_ACEOF
14250 /* confdefs.h. */
14251 _ACEOF
14252 cat confdefs.h >>conftest.$ac_ext
14253 cat >>conftest.$ac_ext <<_ACEOF
14254 /* end confdefs.h. */
14256 #include <signal.h>
14257 #include "$srcdir/src/fault-netbsd-alpha.c"
14258 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
14260 void *fault_address = (void *) (get_fault_addr (scp));
14264 main ()
14266 struct sigaction action;
14269 return 0;
14271 _ACEOF
14272 rm -f conftest.$ac_objext conftest$ac_exeext
14273 if { (ac_try="$ac_link"
14274 case "(($ac_try" in
14275 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14276 *) ac_try_echo=$ac_try;;
14277 esac
14278 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14279 $as_echo "$ac_try_echo") >&5
14280 (eval "$ac_link") 2>conftest.er1
14281 ac_status=$?
14282 grep -v '^ *+' conftest.er1 >conftest.err
14283 rm -f conftest.er1
14284 cat conftest.err >&5
14285 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14286 (exit $ac_status); } && {
14287 test -z "$ac_c_werror_flag" ||
14288 test ! -s conftest.err
14289 } && test -s conftest$ac_exeext && {
14290 test "$cross_compiling" = yes ||
14291 $as_test_x conftest$ac_exeext
14292 }; then
14293 sv_cv_fault_netbsd_alpha="guessing no"
14294 else
14295 $as_echo "$as_me: failed program was:" >&5
14296 sed 's/^/| /' conftest.$ac_ext >&5
14298 sv_cv_fault_netbsd_alpha=no
14301 rm -rf conftest.dSYM
14302 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14303 conftest$ac_exeext conftest.$ac_ext
14305 esac
14307 else
14308 cat >conftest.$ac_ext <<_ACEOF
14310 /* confdefs.h. */
14311 _ACEOF
14312 cat confdefs.h >>conftest.$ac_ext
14313 cat >>conftest.$ac_ext <<_ACEOF
14314 /* end confdefs.h. */
14316 #include <stdlib.h>
14317 #include <signal.h>
14318 #if HAVE_SYS_SIGNAL_H
14319 # include <sys/signal.h>
14320 #endif
14321 #include "$srcdir/src/fault-netbsd-alpha.c"
14322 #include <sys/types.h>
14323 #include <sys/mman.h>
14324 #if HAVE_MMAP_DEVZERO
14325 # include <fcntl.h>
14326 # ifndef MAP_FILE
14327 # define MAP_FILE 0
14328 # endif
14329 #endif
14330 #ifndef PROT_NONE
14331 # define PROT_NONE 0
14332 #endif
14333 #if HAVE_MMAP_ANON
14334 # define zero_fd -1
14335 # define map_flags MAP_ANON | MAP_PRIVATE
14336 #elif HAVE_MMAP_ANONYMOUS
14337 # define zero_fd -1
14338 # define map_flags MAP_ANONYMOUS | MAP_PRIVATE
14339 #elif HAVE_MMAP_DEVZERO
14340 static int zero_fd;
14341 # define map_flags MAP_FILE | MAP_PRIVATE
14342 #endif
14343 unsigned long page;
14344 int handler_called = 0;
14345 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
14347 void *fault_address = (void *) (get_fault_addr (scp));
14348 handler_called++;
14349 if (handler_called == 10)
14350 exit (4);
14351 if (fault_address != (void*)(page + 0x678))
14352 exit (3);
14353 if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
14354 exit (2);
14356 void crasher (unsigned long p)
14358 *(int *) (p + 0x678) = 42;
14360 int main ()
14362 void *p;
14363 struct sigaction action;
14364 /* Preparations. */
14365 #if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
14366 zero_fd = open ("/dev/zero", O_RDONLY, 0644);
14367 #endif
14368 /* Setup some mmaped memory. */
14369 #ifdef __hpux
14370 /* HP-UX 10 mmap() often fails when given a hint. So give the OS complete
14371 freedom about the address range. */
14372 p = mmap ((void *) 0, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
14373 #else
14374 p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
14375 #endif
14376 if (p == (void *)(-1))
14377 exit (2);
14378 page = (unsigned long) p;
14379 /* Make it read-only. */
14380 if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
14381 exit (2);
14382 /* Install the SIGSEGV handler. */
14383 sigemptyset(&action.sa_mask);
14385 action.sa_handler = (void (*) (int)) &sigsegv_handler;
14386 action.sa_flags = 0;
14388 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
14389 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
14390 /* The first write access should invoke the handler and then complete. */
14391 crasher (page);
14392 /* The second write access should not invoke the handler. */
14393 crasher (page);
14394 /* Check that the handler was called only once. */
14395 if (handler_called != 1)
14396 exit (1);
14397 /* Test passed! */
14398 return 0;
14400 _ACEOF
14401 rm -f conftest$ac_exeext
14402 if { (ac_try="$ac_link"
14403 case "(($ac_try" in
14404 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14405 *) ac_try_echo=$ac_try;;
14406 esac
14407 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14408 $as_echo "$ac_try_echo") >&5
14409 (eval "$ac_link") 2>&5
14410 ac_status=$?
14411 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14412 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14413 { (case "(($ac_try" in
14414 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14415 *) ac_try_echo=$ac_try;;
14416 esac
14417 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14418 $as_echo "$ac_try_echo") >&5
14419 (eval "$ac_try") 2>&5
14420 ac_status=$?
14421 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14422 (exit $ac_status); }; }; then
14423 sv_cv_fault_netbsd_alpha=yes
14424 else
14425 $as_echo "$as_me: program exited with status $ac_status" >&5
14426 $as_echo "$as_me: failed program was:" >&5
14427 sed 's/^/| /' conftest.$ac_ext >&5
14429 ( exit $ac_status )
14430 sv_cv_fault_netbsd_alpha=no
14432 rm -rf conftest.dSYM
14433 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14439 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_netbsd_alpha" >&5
14440 $as_echo "$sv_cv_fault_netbsd_alpha" >&6; }
14447 { $as_echo "$as_me:$LINENO: checking whether a fault handler according to AIX works" >&5
14448 $as_echo_n "checking whether a fault handler according to AIX works... " >&6; }
14449 if test "${sv_cv_fault_aix+set}" = set; then
14450 $as_echo_n "(cached) " >&6
14451 else
14453 if test "$cross_compiling" = yes; then
14454 case "$host" in
14455 *-*-aix[34]*) sv_cv_fault_aix=yes ;;
14457 cat >conftest.$ac_ext <<_ACEOF
14459 /* confdefs.h. */
14460 _ACEOF
14461 cat confdefs.h >>conftest.$ac_ext
14462 cat >>conftest.$ac_ext <<_ACEOF
14463 /* end confdefs.h. */
14465 #include <signal.h>
14467 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
14469 void *fault_address = (void *) (scp->sc_jmpbuf.jmp_context.o_vaddr);
14473 main ()
14475 struct sigaction action;
14478 return 0;
14480 _ACEOF
14481 rm -f conftest.$ac_objext conftest$ac_exeext
14482 if { (ac_try="$ac_link"
14483 case "(($ac_try" in
14484 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14485 *) ac_try_echo=$ac_try;;
14486 esac
14487 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14488 $as_echo "$ac_try_echo") >&5
14489 (eval "$ac_link") 2>conftest.er1
14490 ac_status=$?
14491 grep -v '^ *+' conftest.er1 >conftest.err
14492 rm -f conftest.er1
14493 cat conftest.err >&5
14494 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14495 (exit $ac_status); } && {
14496 test -z "$ac_c_werror_flag" ||
14497 test ! -s conftest.err
14498 } && test -s conftest$ac_exeext && {
14499 test "$cross_compiling" = yes ||
14500 $as_test_x conftest$ac_exeext
14501 }; then
14502 sv_cv_fault_aix="guessing no"
14503 else
14504 $as_echo "$as_me: failed program was:" >&5
14505 sed 's/^/| /' conftest.$ac_ext >&5
14507 sv_cv_fault_aix=no
14510 rm -rf conftest.dSYM
14511 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14512 conftest$ac_exeext conftest.$ac_ext
14514 esac
14516 else
14517 cat >conftest.$ac_ext <<_ACEOF
14519 /* confdefs.h. */
14520 _ACEOF
14521 cat confdefs.h >>conftest.$ac_ext
14522 cat >>conftest.$ac_ext <<_ACEOF
14523 /* end confdefs.h. */
14525 #include <stdlib.h>
14526 #include <signal.h>
14527 #if HAVE_SYS_SIGNAL_H
14528 # include <sys/signal.h>
14529 #endif
14531 #include <sys/types.h>
14532 #include <sys/mman.h>
14533 #if HAVE_MMAP_DEVZERO
14534 # include <fcntl.h>
14535 # ifndef MAP_FILE
14536 # define MAP_FILE 0
14537 # endif
14538 #endif
14539 #ifndef PROT_NONE
14540 # define PROT_NONE 0
14541 #endif
14542 #if HAVE_MMAP_ANON
14543 # define zero_fd -1
14544 # define map_flags MAP_ANON | MAP_PRIVATE
14545 #elif HAVE_MMAP_ANONYMOUS
14546 # define zero_fd -1
14547 # define map_flags MAP_ANONYMOUS | MAP_PRIVATE
14548 #elif HAVE_MMAP_DEVZERO
14549 static int zero_fd;
14550 # define map_flags MAP_FILE | MAP_PRIVATE
14551 #endif
14552 unsigned long page;
14553 int handler_called = 0;
14554 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
14556 void *fault_address = (void *) (scp->sc_jmpbuf.jmp_context.o_vaddr);
14557 handler_called++;
14558 if (handler_called == 10)
14559 exit (4);
14560 if (fault_address != (void*)(page + 0x678))
14561 exit (3);
14562 if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
14563 exit (2);
14565 void crasher (unsigned long p)
14567 *(int *) (p + 0x678) = 42;
14569 int main ()
14571 void *p;
14572 struct sigaction action;
14573 /* Preparations. */
14574 #if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
14575 zero_fd = open ("/dev/zero", O_RDONLY, 0644);
14576 #endif
14577 /* Setup some mmaped memory. */
14578 #ifdef __hpux
14579 /* HP-UX 10 mmap() often fails when given a hint. So give the OS complete
14580 freedom about the address range. */
14581 p = mmap ((void *) 0, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
14582 #else
14583 p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
14584 #endif
14585 if (p == (void *)(-1))
14586 exit (2);
14587 page = (unsigned long) p;
14588 /* Make it read-only. */
14589 if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
14590 exit (2);
14591 /* Install the SIGSEGV handler. */
14592 sigemptyset(&action.sa_mask);
14594 action.sa_handler = (void (*) (int)) &sigsegv_handler;
14595 action.sa_flags = 0;
14597 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
14598 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
14599 /* The first write access should invoke the handler and then complete. */
14600 crasher (page);
14601 /* The second write access should not invoke the handler. */
14602 crasher (page);
14603 /* Check that the handler was called only once. */
14604 if (handler_called != 1)
14605 exit (1);
14606 /* Test passed! */
14607 return 0;
14609 _ACEOF
14610 rm -f conftest$ac_exeext
14611 if { (ac_try="$ac_link"
14612 case "(($ac_try" in
14613 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14614 *) ac_try_echo=$ac_try;;
14615 esac
14616 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14617 $as_echo "$ac_try_echo") >&5
14618 (eval "$ac_link") 2>&5
14619 ac_status=$?
14620 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14621 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14622 { (case "(($ac_try" in
14623 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14624 *) ac_try_echo=$ac_try;;
14625 esac
14626 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14627 $as_echo "$ac_try_echo") >&5
14628 (eval "$ac_try") 2>&5
14629 ac_status=$?
14630 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14631 (exit $ac_status); }; }; then
14632 sv_cv_fault_aix=yes
14633 else
14634 $as_echo "$as_me: program exited with status $ac_status" >&5
14635 $as_echo "$as_me: failed program was:" >&5
14636 sed 's/^/| /' conftest.$ac_ext >&5
14638 ( exit $ac_status )
14639 sv_cv_fault_aix=no
14641 rm -rf conftest.dSYM
14642 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14648 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_aix" >&5
14649 $as_echo "$sv_cv_fault_aix" >&6; }
14656 { $as_echo "$as_me:$LINENO: checking whether a fault handler according to MacOSX/Darwin7 PowerPC works" >&5
14657 $as_echo_n "checking whether a fault handler according to MacOSX/Darwin7 PowerPC works... " >&6; }
14658 if test "${sv_cv_fault_macosdarwin7_ppc+set}" = set; then
14659 $as_echo_n "(cached) " >&6
14660 else
14662 if test "$cross_compiling" = yes; then
14663 case "$host" in
14664 powerpc-*-darwin7*) sv_cv_fault_macosdarwin7_ppc=yes ;;
14666 cat >conftest.$ac_ext <<_ACEOF
14668 /* confdefs.h. */
14669 _ACEOF
14670 cat confdefs.h >>conftest.$ac_ext
14671 cat >>conftest.$ac_ext <<_ACEOF
14672 /* end confdefs.h. */
14674 #include <signal.h>
14675 #include "$srcdir/src/fault-macosdarwin7-powerpc.c"
14676 void sigsegv_handler (int sig, siginfo_t *sip, ucontext_t *ucp)
14678 void *fault_address = (void *) (get_fault_addr (sip, ucp));
14682 main ()
14684 struct sigaction action;
14685 action.sa_sigaction = &sigsegv_handler;
14686 action.sa_flags = SA_SIGINFO;
14688 return 0;
14690 _ACEOF
14691 rm -f conftest.$ac_objext conftest$ac_exeext
14692 if { (ac_try="$ac_link"
14693 case "(($ac_try" in
14694 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14695 *) ac_try_echo=$ac_try;;
14696 esac
14697 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14698 $as_echo "$ac_try_echo") >&5
14699 (eval "$ac_link") 2>conftest.er1
14700 ac_status=$?
14701 grep -v '^ *+' conftest.er1 >conftest.err
14702 rm -f conftest.er1
14703 cat conftest.err >&5
14704 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14705 (exit $ac_status); } && {
14706 test -z "$ac_c_werror_flag" ||
14707 test ! -s conftest.err
14708 } && test -s conftest$ac_exeext && {
14709 test "$cross_compiling" = yes ||
14710 $as_test_x conftest$ac_exeext
14711 }; then
14712 sv_cv_fault_macosdarwin7_ppc="guessing no"
14713 else
14714 $as_echo "$as_me: failed program was:" >&5
14715 sed 's/^/| /' conftest.$ac_ext >&5
14717 sv_cv_fault_macosdarwin7_ppc=no
14720 rm -rf conftest.dSYM
14721 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14722 conftest$ac_exeext conftest.$ac_ext
14724 esac
14726 else
14727 cat >conftest.$ac_ext <<_ACEOF
14729 /* confdefs.h. */
14730 _ACEOF
14731 cat confdefs.h >>conftest.$ac_ext
14732 cat >>conftest.$ac_ext <<_ACEOF
14733 /* end confdefs.h. */
14735 #include <stdlib.h>
14736 #include <signal.h>
14737 #if HAVE_SYS_SIGNAL_H
14738 # include <sys/signal.h>
14739 #endif
14740 #include "$srcdir/src/fault-macosdarwin7-powerpc.c"
14741 #include <sys/types.h>
14742 #include <sys/mman.h>
14743 #if HAVE_MMAP_DEVZERO
14744 # include <fcntl.h>
14745 # ifndef MAP_FILE
14746 # define MAP_FILE 0
14747 # endif
14748 #endif
14749 #ifndef PROT_NONE
14750 # define PROT_NONE 0
14751 #endif
14752 #if HAVE_MMAP_ANON
14753 # define zero_fd -1
14754 # define map_flags MAP_ANON | MAP_PRIVATE
14755 #elif HAVE_MMAP_ANONYMOUS
14756 # define zero_fd -1
14757 # define map_flags MAP_ANONYMOUS | MAP_PRIVATE
14758 #elif HAVE_MMAP_DEVZERO
14759 static int zero_fd;
14760 # define map_flags MAP_FILE | MAP_PRIVATE
14761 #endif
14762 unsigned long page;
14763 int handler_called = 0;
14764 void sigsegv_handler (int sig, siginfo_t *sip, ucontext_t *ucp)
14766 void *fault_address = (void *) (get_fault_addr (sip, ucp));
14767 handler_called++;
14768 if (handler_called == 10)
14769 exit (4);
14770 if (fault_address != (void*)(page + 0x678))
14771 exit (3);
14772 if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
14773 exit (2);
14775 void crasher (unsigned long p)
14777 *(int *) (p + 0x678) = 42;
14779 int main ()
14781 void *p;
14782 struct sigaction action;
14783 /* Preparations. */
14784 #if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
14785 zero_fd = open ("/dev/zero", O_RDONLY, 0644);
14786 #endif
14787 /* Setup some mmaped memory. */
14788 #ifdef __hpux
14789 /* HP-UX 10 mmap() often fails when given a hint. So give the OS complete
14790 freedom about the address range. */
14791 p = mmap ((void *) 0, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
14792 #else
14793 p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
14794 #endif
14795 if (p == (void *)(-1))
14796 exit (2);
14797 page = (unsigned long) p;
14798 /* Make it read-only. */
14799 if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
14800 exit (2);
14801 /* Install the SIGSEGV handler. */
14802 sigemptyset(&action.sa_mask);
14803 action.sa_sigaction = &sigsegv_handler;
14804 action.sa_flags = SA_SIGINFO;
14805 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
14806 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
14807 /* The first write access should invoke the handler and then complete. */
14808 crasher (page);
14809 /* The second write access should not invoke the handler. */
14810 crasher (page);
14811 /* Check that the handler was called only once. */
14812 if (handler_called != 1)
14813 exit (1);
14814 /* Test passed! */
14815 return 0;
14817 _ACEOF
14818 rm -f conftest$ac_exeext
14819 if { (ac_try="$ac_link"
14820 case "(($ac_try" in
14821 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14822 *) ac_try_echo=$ac_try;;
14823 esac
14824 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14825 $as_echo "$ac_try_echo") >&5
14826 (eval "$ac_link") 2>&5
14827 ac_status=$?
14828 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14829 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14830 { (case "(($ac_try" in
14831 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14832 *) ac_try_echo=$ac_try;;
14833 esac
14834 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14835 $as_echo "$ac_try_echo") >&5
14836 (eval "$ac_try") 2>&5
14837 ac_status=$?
14838 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14839 (exit $ac_status); }; }; then
14840 sv_cv_fault_macosdarwin7_ppc=yes
14841 else
14842 $as_echo "$as_me: program exited with status $ac_status" >&5
14843 $as_echo "$as_me: failed program was:" >&5
14844 sed 's/^/| /' conftest.$ac_ext >&5
14846 ( exit $ac_status )
14847 sv_cv_fault_macosdarwin7_ppc=no
14849 rm -rf conftest.dSYM
14850 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14856 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_macosdarwin7_ppc" >&5
14857 $as_echo "$sv_cv_fault_macosdarwin7_ppc" >&6; }
14860 if test "$sv_cv_fault_macosdarwin7_ppc" != yes; then
14865 { $as_echo "$as_me:$LINENO: checking whether a fault handler according to MacOSX/Darwin5 PowerPC works" >&5
14866 $as_echo_n "checking whether a fault handler according to MacOSX/Darwin5 PowerPC works... " >&6; }
14867 if test "${sv_cv_fault_macosdarwin5_ppc+set}" = set; then
14868 $as_echo_n "(cached) " >&6
14869 else
14871 if test "$cross_compiling" = yes; then
14872 case "$host" in
14873 powerpc-*-darwin5*) sv_cv_fault_macosdarwin5_ppc=yes ;;
14875 cat >conftest.$ac_ext <<_ACEOF
14877 /* confdefs.h. */
14878 _ACEOF
14879 cat confdefs.h >>conftest.$ac_ext
14880 cat >>conftest.$ac_ext <<_ACEOF
14881 /* end confdefs.h. */
14883 #include <signal.h>
14884 #include "$srcdir/src/fault-macosdarwin5-powerpc.c"
14885 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
14887 void *fault_address = (void *) (get_fault_addr (scp));
14891 main ()
14893 struct sigaction action;
14896 return 0;
14898 _ACEOF
14899 rm -f conftest.$ac_objext conftest$ac_exeext
14900 if { (ac_try="$ac_link"
14901 case "(($ac_try" in
14902 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14903 *) ac_try_echo=$ac_try;;
14904 esac
14905 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14906 $as_echo "$ac_try_echo") >&5
14907 (eval "$ac_link") 2>conftest.er1
14908 ac_status=$?
14909 grep -v '^ *+' conftest.er1 >conftest.err
14910 rm -f conftest.er1
14911 cat conftest.err >&5
14912 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14913 (exit $ac_status); } && {
14914 test -z "$ac_c_werror_flag" ||
14915 test ! -s conftest.err
14916 } && test -s conftest$ac_exeext && {
14917 test "$cross_compiling" = yes ||
14918 $as_test_x conftest$ac_exeext
14919 }; then
14920 sv_cv_fault_macosdarwin5_ppc="guessing no"
14921 else
14922 $as_echo "$as_me: failed program was:" >&5
14923 sed 's/^/| /' conftest.$ac_ext >&5
14925 sv_cv_fault_macosdarwin5_ppc=no
14928 rm -rf conftest.dSYM
14929 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14930 conftest$ac_exeext conftest.$ac_ext
14932 esac
14934 else
14935 cat >conftest.$ac_ext <<_ACEOF
14937 /* confdefs.h. */
14938 _ACEOF
14939 cat confdefs.h >>conftest.$ac_ext
14940 cat >>conftest.$ac_ext <<_ACEOF
14941 /* end confdefs.h. */
14943 #include <stdlib.h>
14944 #include <signal.h>
14945 #if HAVE_SYS_SIGNAL_H
14946 # include <sys/signal.h>
14947 #endif
14948 #include "$srcdir/src/fault-macosdarwin5-powerpc.c"
14949 #include <sys/types.h>
14950 #include <sys/mman.h>
14951 #if HAVE_MMAP_DEVZERO
14952 # include <fcntl.h>
14953 # ifndef MAP_FILE
14954 # define MAP_FILE 0
14955 # endif
14956 #endif
14957 #ifndef PROT_NONE
14958 # define PROT_NONE 0
14959 #endif
14960 #if HAVE_MMAP_ANON
14961 # define zero_fd -1
14962 # define map_flags MAP_ANON | MAP_PRIVATE
14963 #elif HAVE_MMAP_ANONYMOUS
14964 # define zero_fd -1
14965 # define map_flags MAP_ANONYMOUS | MAP_PRIVATE
14966 #elif HAVE_MMAP_DEVZERO
14967 static int zero_fd;
14968 # define map_flags MAP_FILE | MAP_PRIVATE
14969 #endif
14970 unsigned long page;
14971 int handler_called = 0;
14972 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
14974 void *fault_address = (void *) (get_fault_addr (scp));
14975 handler_called++;
14976 if (handler_called == 10)
14977 exit (4);
14978 if (fault_address != (void*)(page + 0x678))
14979 exit (3);
14980 if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
14981 exit (2);
14983 void crasher (unsigned long p)
14985 *(int *) (p + 0x678) = 42;
14987 int main ()
14989 void *p;
14990 struct sigaction action;
14991 /* Preparations. */
14992 #if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
14993 zero_fd = open ("/dev/zero", O_RDONLY, 0644);
14994 #endif
14995 /* Setup some mmaped memory. */
14996 #ifdef __hpux
14997 /* HP-UX 10 mmap() often fails when given a hint. So give the OS complete
14998 freedom about the address range. */
14999 p = mmap ((void *) 0, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
15000 #else
15001 p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
15002 #endif
15003 if (p == (void *)(-1))
15004 exit (2);
15005 page = (unsigned long) p;
15006 /* Make it read-only. */
15007 if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
15008 exit (2);
15009 /* Install the SIGSEGV handler. */
15010 sigemptyset(&action.sa_mask);
15012 action.sa_handler = (void (*) (int)) &sigsegv_handler;
15013 action.sa_flags = 0;
15015 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
15016 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
15017 /* The first write access should invoke the handler and then complete. */
15018 crasher (page);
15019 /* The second write access should not invoke the handler. */
15020 crasher (page);
15021 /* Check that the handler was called only once. */
15022 if (handler_called != 1)
15023 exit (1);
15024 /* Test passed! */
15025 return 0;
15027 _ACEOF
15028 rm -f conftest$ac_exeext
15029 if { (ac_try="$ac_link"
15030 case "(($ac_try" in
15031 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15032 *) ac_try_echo=$ac_try;;
15033 esac
15034 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15035 $as_echo "$ac_try_echo") >&5
15036 (eval "$ac_link") 2>&5
15037 ac_status=$?
15038 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15039 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15040 { (case "(($ac_try" in
15041 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15042 *) ac_try_echo=$ac_try;;
15043 esac
15044 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15045 $as_echo "$ac_try_echo") >&5
15046 (eval "$ac_try") 2>&5
15047 ac_status=$?
15048 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15049 (exit $ac_status); }; }; then
15050 sv_cv_fault_macosdarwin5_ppc=yes
15051 else
15052 $as_echo "$as_me: program exited with status $ac_status" >&5
15053 $as_echo "$as_me: failed program was:" >&5
15054 sed 's/^/| /' conftest.$ac_ext >&5
15056 ( exit $ac_status )
15057 sv_cv_fault_macosdarwin5_ppc=no
15059 rm -rf conftest.dSYM
15060 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15066 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_macosdarwin5_ppc" >&5
15067 $as_echo "$sv_cv_fault_macosdarwin5_ppc" >&6; }
15075 { $as_echo "$as_me:$LINENO: checking whether a fault handler according to Hurd works" >&5
15076 $as_echo_n "checking whether a fault handler according to Hurd works... " >&6; }
15077 if test "${sv_cv_fault_hurd+set}" = set; then
15078 $as_echo_n "(cached) " >&6
15079 else
15081 if test "$cross_compiling" = yes; then
15082 case "$host" in
15085 cat >conftest.$ac_ext <<_ACEOF
15087 /* confdefs.h. */
15088 _ACEOF
15089 cat confdefs.h >>conftest.$ac_ext
15090 cat >>conftest.$ac_ext <<_ACEOF
15091 /* end confdefs.h. */
15093 #include <signal.h>
15095 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
15097 void *fault_address = (void *) (code);
15101 main ()
15103 struct sigaction action;
15106 return 0;
15108 _ACEOF
15109 rm -f conftest.$ac_objext conftest$ac_exeext
15110 if { (ac_try="$ac_link"
15111 case "(($ac_try" in
15112 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15113 *) ac_try_echo=$ac_try;;
15114 esac
15115 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15116 $as_echo "$ac_try_echo") >&5
15117 (eval "$ac_link") 2>conftest.er1
15118 ac_status=$?
15119 grep -v '^ *+' conftest.er1 >conftest.err
15120 rm -f conftest.er1
15121 cat conftest.err >&5
15122 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15123 (exit $ac_status); } && {
15124 test -z "$ac_c_werror_flag" ||
15125 test ! -s conftest.err
15126 } && test -s conftest$ac_exeext && {
15127 test "$cross_compiling" = yes ||
15128 $as_test_x conftest$ac_exeext
15129 }; then
15130 sv_cv_fault_hurd="guessing no"
15131 else
15132 $as_echo "$as_me: failed program was:" >&5
15133 sed 's/^/| /' conftest.$ac_ext >&5
15135 sv_cv_fault_hurd=no
15138 rm -rf conftest.dSYM
15139 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15140 conftest$ac_exeext conftest.$ac_ext
15142 esac
15144 else
15145 cat >conftest.$ac_ext <<_ACEOF
15147 /* confdefs.h. */
15148 _ACEOF
15149 cat confdefs.h >>conftest.$ac_ext
15150 cat >>conftest.$ac_ext <<_ACEOF
15151 /* end confdefs.h. */
15153 #include <stdlib.h>
15154 #include <signal.h>
15155 #if HAVE_SYS_SIGNAL_H
15156 # include <sys/signal.h>
15157 #endif
15159 #include <sys/types.h>
15160 #include <sys/mman.h>
15161 #if HAVE_MMAP_DEVZERO
15162 # include <fcntl.h>
15163 # ifndef MAP_FILE
15164 # define MAP_FILE 0
15165 # endif
15166 #endif
15167 #ifndef PROT_NONE
15168 # define PROT_NONE 0
15169 #endif
15170 #if HAVE_MMAP_ANON
15171 # define zero_fd -1
15172 # define map_flags MAP_ANON | MAP_PRIVATE
15173 #elif HAVE_MMAP_ANONYMOUS
15174 # define zero_fd -1
15175 # define map_flags MAP_ANONYMOUS | MAP_PRIVATE
15176 #elif HAVE_MMAP_DEVZERO
15177 static int zero_fd;
15178 # define map_flags MAP_FILE | MAP_PRIVATE
15179 #endif
15180 unsigned long page;
15181 int handler_called = 0;
15182 void sigsegv_handler (int sig, int code, struct sigcontext *scp)
15184 void *fault_address = (void *) (code);
15185 handler_called++;
15186 if (handler_called == 10)
15187 exit (4);
15188 if (fault_address != (void*)(page + 0x678))
15189 exit (3);
15190 if (mprotect ((void *) page, 0x10000, PROT_READ | PROT_WRITE) < 0)
15191 exit (2);
15193 void crasher (unsigned long p)
15195 *(int *) (p + 0x678) = 42;
15197 int main ()
15199 void *p;
15200 struct sigaction action;
15201 /* Preparations. */
15202 #if !HAVE_MMAP_ANON && !HAVE_MMAP_ANONYMOUS && HAVE_MMAP_DEVZERO
15203 zero_fd = open ("/dev/zero", O_RDONLY, 0644);
15204 #endif
15205 /* Setup some mmaped memory. */
15206 #ifdef __hpux
15207 /* HP-UX 10 mmap() often fails when given a hint. So give the OS complete
15208 freedom about the address range. */
15209 p = mmap ((void *) 0, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
15210 #else
15211 p = mmap ((void *) 0x12340000, 0x10000, PROT_READ | PROT_WRITE, map_flags, zero_fd, 0);
15212 #endif
15213 if (p == (void *)(-1))
15214 exit (2);
15215 page = (unsigned long) p;
15216 /* Make it read-only. */
15217 if (mprotect ((void *) page, 0x10000, PROT_READ) < 0)
15218 exit (2);
15219 /* Install the SIGSEGV handler. */
15220 sigemptyset(&action.sa_mask);
15222 action.sa_handler = (void (*) (int)) &sigsegv_handler;
15223 action.sa_flags = 0;
15225 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
15226 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
15227 /* The first write access should invoke the handler and then complete. */
15228 crasher (page);
15229 /* The second write access should not invoke the handler. */
15230 crasher (page);
15231 /* Check that the handler was called only once. */
15232 if (handler_called != 1)
15233 exit (1);
15234 /* Test passed! */
15235 return 0;
15237 _ACEOF
15238 rm -f conftest$ac_exeext
15239 if { (ac_try="$ac_link"
15240 case "(($ac_try" in
15241 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15242 *) ac_try_echo=$ac_try;;
15243 esac
15244 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15245 $as_echo "$ac_try_echo") >&5
15246 (eval "$ac_link") 2>&5
15247 ac_status=$?
15248 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15249 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15250 { (case "(($ac_try" in
15251 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15252 *) ac_try_echo=$ac_try;;
15253 esac
15254 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15255 $as_echo "$ac_try_echo") >&5
15256 (eval "$ac_try") 2>&5
15257 ac_status=$?
15258 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15259 (exit $ac_status); }; }; then
15260 sv_cv_fault_hurd=yes
15261 else
15262 $as_echo "$as_me: program exited with status $ac_status" >&5
15263 $as_echo "$as_me: failed program was:" >&5
15264 sed 's/^/| /' conftest.$ac_ext >&5
15266 ( exit $ac_status )
15267 sv_cv_fault_hurd=no
15269 rm -rf conftest.dSYM
15270 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15276 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_hurd" >&5
15277 $as_echo "$sv_cv_fault_hurd" >&6; }
15280 # End of MacOS X special casing.
15282 esac
15284 CFG_HANDLER=
15285 CFG_FAULT=
15286 CFG_MACHFAULT=
15287 FAULT_CONTEXT=void
15288 FAULT_CONTEXT_INCLUDE=
15289 if test -z "$CFG_FAULT" && test "$sv_cv_fault_aix" = yes; then
15290 case "$host_cpu" in
15291 powerpc* | rs6000) CFG_FAULT=fault-aix3-powerpc.h ;;
15292 *) CFG_FAULT=fault-aix3.h ;;
15293 esac
15294 FAULT_CONTEXT='struct sigcontext'
15296 if test -z "$CFG_FAULT" && test "$sv_cv_fault_irix" = yes; then
15297 case "$host_cpu" in
15298 mips*) CFG_FAULT=fault-irix-mips.h ;;
15299 *) CFG_FAULT=fault-irix.h ;;
15300 esac
15301 FAULT_CONTEXT='struct sigcontext'
15303 if test -z "$CFG_FAULT" && test "$sv_cv_fault_hpux_hppa" = yes; then
15304 case "$host_cpu" in
15305 hppa* | parisc*) CFG_FAULT=fault-hpux-hppa.h ;;
15306 *) CFG_FAULT=fault-hpux.h ;;
15307 esac
15308 FAULT_CONTEXT='struct sigcontext'
15310 if test -z "$CFG_FAULT" && test "$sv_cv_fault_osf_alpha" = yes; then
15311 case "$host_cpu" in
15312 alpha*) CFG_FAULT=fault-osf-alpha.h ;;
15313 *) CFG_FAULT=fault-osf.h ;;
15314 esac
15315 FAULT_CONTEXT='struct sigcontext'
15317 if test -z "$CFG_FAULT" && test "$sv_cv_fault_netbsd_alpha" = yes; then
15318 case "$host_cpu" in
15319 alpha*) CFG_FAULT=fault-netbsd-alpha.h ;;
15320 esac
15321 FAULT_CONTEXT='struct sigcontext'
15323 if test -z "$CFG_FAULT" && test "$sv_cv_fault_linux_i386" = yes; then
15324 case "$host_cpu" in
15325 i?86 | x86_64) CFG_FAULT=fault-linux-i386.h ;;
15326 esac
15327 FAULT_CONTEXT='struct sigcontext'
15329 if test -z "$CFG_FAULT" && test "$sv_cv_fault_linux_i386_old" = yes; then
15330 case "$host_cpu" in
15331 i?86 | x86_64) CFG_FAULT=fault-linux-i386-old.h ;;
15332 esac
15333 FAULT_CONTEXT='struct sigcontext'
15335 if test -z "$CFG_FAULT" && test "$sv_cv_fault_linux_powerpc" = yes; then
15336 case "$host_cpu" in
15337 powerpc* | rs6000) CFG_FAULT=fault-linux-powerpc.h ;;
15338 esac
15339 FAULT_CONTEXT='struct sigcontext'
15341 if test -z "$CFG_FAULT" && test "$sv_cv_fault_linux_hppa" = yes; then
15342 case "$host_cpu" in
15343 hppa* | parisc*) CFG_FAULT=fault-linux-hppa.h ;;
15344 esac
15346 if test -z "$CFG_FAULT" && test "$sv_cv_fault_hurd" = yes; then
15347 case "$host_os" in
15348 netbsd*) # A false positive.
15351 CFG_FAULT=fault-hurd.h
15352 FAULT_CONTEXT='struct sigcontext'
15354 esac
15356 if test -z "$CFG_FAULT" && test "$sv_cv_fault_bsd" = yes; then
15357 case "$host_os" in
15358 freebsd* | dragonfly* | kfreebsd*)
15359 case "$host_cpu" in
15360 i?86 | x86_64)
15361 CFG_FAULT=fault-freebsd-i386.h
15362 FAULT_CONTEXT='struct sigcontext'
15365 CFG_FAULT=fault-bsd.h
15366 FAULT_CONTEXT='void'
15368 esac
15371 CFG_FAULT=fault-bsd.h
15372 FAULT_CONTEXT='void'
15374 esac
15376 if test -z "$CFG_FAULT" && test "$sv_cv_fault_posix" = yes; then
15377 case "$host_os" in
15378 openbsd*)
15379 case "$host_cpu" in
15380 i?86 | x86_64) CFG_FAULT=fault-openbsd-i386.h ;;
15381 *) CFG_FAULT=fault-openbsd.h ;;
15382 esac
15383 FAULT_CONTEXT='struct sigcontext'
15385 linux*)
15386 case "$host_cpu" in
15387 ia64)
15388 CFG_FAULT=fault-linux-ia64.h
15389 FAULT_CONTEXT='struct sigcontext'
15391 esac
15393 esac
15394 if test -z "$CFG_FAULT"; then
15395 case "$host_os" in
15396 solaris*)
15397 case "$host_cpu" in
15398 i?86 | x86_64) CFG_FAULT=fault-solaris-i386.h ;;
15399 sparc*) CFG_FAULT=fault-solaris-sparc.h ;;
15400 *) CFG_FAULT=fault-solaris.h ;;
15401 esac
15403 aix*)
15404 case "$host_cpu" in
15405 powerpc* | rs6000) CFG_FAULT=fault-aix5-powerpc.h ;;
15406 *) CFG_FAULT=fault-aix5.h ;;
15407 esac
15409 netbsd*)
15410 CFG_FAULT=fault-netbsd.h
15413 CFG_FAULT=fault-posix.h
15415 esac
15416 FAULT_CONTEXT='ucontext_t'
15417 FAULT_CONTEXT_INCLUDE='#include <ucontext.h>'
15420 if test -z "$CFG_FAULT"; then
15421 case "$host_os" in
15422 macos* | darwin[6-9]* | darwin[1-9][0-9]*)
15423 case "$host_cpu" in
15424 powerpc* | rs6000 | i?86 | x86_64)
15425 CFG_MACHFAULT=machfault-macos.h
15426 FAULT_CONTEXT_INCLUDE='#include <signal.h>
15427 #include <mach/thread_status.h>
15428 #if defined __ppc64__
15429 #define sigsegv_thread_state_t ppc_thread_state64_t
15430 #elif defined __ppc__
15431 #define sigsegv_thread_state_t ppc_thread_state_t
15432 #endif
15433 #if defined __x86_64__
15434 #define sigsegv_thread_state_t x86_thread_state64_t
15435 #elif defined __i386__
15436 #if defined x86_THREAD_STATE32
15437 #define sigsegv_thread_state_t x86_thread_state32_t
15438 #else
15439 #define sigsegv_thread_state_t i386_thread_state_t
15440 #endif
15441 #endif'
15442 FAULT_CONTEXT='sigsegv_thread_state_t'
15444 esac
15445 if test -n "$CFG_MACHFAULT"; then
15446 CFG_HANDLER=handler-macos.c
15447 CFG_FAULT=fault-macos.h # nonexistent, just a dummy
15450 esac
15452 if test -z "$CFG_FAULT" && test "$sv_cv_fault_linux_m68k" = yes; then
15453 case "$host_cpu" in
15454 m68*)
15455 CFG_FAULT=fault-linux-m68k.h
15456 FAULT_CONTEXT='struct sigcontext'
15458 esac
15460 if test -z "$CFG_FAULT" && test "$sv_cv_fault_macosdarwin7_ppc" = yes; then
15461 case "$host_cpu" in
15462 powerpc* | rs6000)
15463 CFG_FAULT=fault-macosdarwin7-powerpc.h
15464 FAULT_CONTEXT='ucontext_t'
15465 FAULT_CONTEXT_INCLUDE='#include <signal.h>
15466 #include <ucontext.h>'
15468 esac
15470 if test -z "$CFG_FAULT" && test "$sv_cv_fault_macosdarwin5_ppc" = yes; then
15471 case "$host_cpu" in
15472 powerpc* | rs6000)
15473 CFG_FAULT=fault-macosdarwin5-powerpc.h
15474 FAULT_CONTEXT='struct sigcontext'
15476 esac
15478 if test -z "$CFG_FAULT"; then
15479 case "$host_os" in
15480 mingw* | cygwin*)
15481 FAULT_CONTEXT='CONTEXT'
15482 FAULT_CONTEXT_INCLUDE='#include <windows.h>'
15483 CFG_FAULT=fault-win32.h # nonexistent, just a dummy
15485 esac
15487 if test -n "$CFG_FAULT"; then
15488 sv_cv_have_sigsegv_recovery=yes
15489 else
15490 sv_cv_have_sigsegv_recovery=no
15491 case "$host_os" in
15492 linux*)
15493 case "$host_cpu" in
15494 alpha*)
15495 CFG_FAULT=fault-linux-alpha.h
15496 FAULT_CONTEXT='struct sigcontext'
15498 arm* | strongarm* | xscale*)
15499 CFG_FAULT=fault-linux-arm.h
15500 FAULT_CONTEXT='struct sigcontext'
15502 cris)
15503 CFG_FAULT=fault-linux-cris.h
15504 FAULT_CONTEXT='struct sigcontext'
15506 mips*)
15507 CFG_FAULT=fault-linux-mips.h
15508 FAULT_CONTEXT='struct sigcontext'
15510 s390*)
15511 CFG_FAULT=fault-linux-s390.h
15512 FAULT_CONTEXT='struct sigcontext'
15514 sh*)
15515 CFG_FAULT=fault-linux-sh.h
15516 FAULT_CONTEXT='struct sigcontext'
15518 sparc*)
15519 CFG_FAULT=fault-linux-sparc.h
15520 FAULT_CONTEXT='struct sigcontext'
15522 x86_64)
15523 CFG_FAULT=fault-linux-x86_64.h
15524 FAULT_CONTEXT='struct sigcontext'
15526 esac
15528 beos*)
15529 case "$host_cpu" in
15530 i?86 | x86_64) CFG_FAULT=fault-beos-i386.h ;;
15531 *) CFG_FAULT=fault-beos.h ;;
15532 esac
15533 FAULT_CONTEXT='struct vregs'
15535 macos* | darwin*)
15536 case "$host_cpu" in
15537 i?86 | x86_64) CFG_FAULT=fault-macos-i386.h ;;
15538 esac
15539 FAULT_CONTEXT='struct sigcontext'
15541 esac
15543 { $as_echo "$as_me:$LINENO: checking for the fault handler specifics" >&5
15544 $as_echo_n "checking for the fault handler specifics... " >&6; }
15545 if test -n "$CFG_FAULT"; then
15546 sv_cv_fault_include=$CFG_FAULT
15547 else
15548 if test -n "$CFG_MACHFAULT"; then
15549 sv_cv_fault_include=$CFG_MACHFAULT
15550 else
15551 sv_cv_fault_include=none
15554 { $as_echo "$as_me:$LINENO: result: $sv_cv_fault_include" >&5
15555 $as_echo "$sv_cv_fault_include" >&6; }
15556 if test -z "$CFG_FAULT"; then
15557 CFG_FAULT=fault-none.h
15560 cat >>confdefs.h <<_ACEOF
15561 #define CFG_FAULT "$CFG_FAULT"
15562 _ACEOF
15564 if test -z "$CFG_MACHFAULT"; then
15565 CFG_MACHFAULT=fault-none.h
15568 cat >>confdefs.h <<_ACEOF
15569 #define CFG_MACHFAULT "$CFG_MACHFAULT"
15570 _ACEOF
15575 { $as_echo "$as_me:$LINENO: checking if the system supports catching SIGSEGV" >&5
15576 $as_echo_n "checking if the system supports catching SIGSEGV... " >&6; }
15577 { $as_echo "$as_me:$LINENO: result: $sv_cv_have_sigsegv_recovery" >&5
15578 $as_echo "$sv_cv_have_sigsegv_recovery" >&6; }
15579 if test $sv_cv_have_sigsegv_recovery != no; then
15580 HAVE_SIGSEGV_RECOVERY=1
15581 else
15582 HAVE_SIGSEGV_RECOVERY=0
15587 { $as_echo "$as_me:$LINENO: checking for stack direction" >&5
15588 $as_echo_n "checking for stack direction... " >&6; }
15589 if test "${sv_cv_stack_direction_msg+set}" = set; then
15590 $as_echo_n "(cached) " >&6
15591 else
15593 case "$host_cpu" in
15594 a29k | \
15595 alpha* | \
15596 arc | \
15597 arm* | strongarm* | xscale* | \
15598 avr | \
15599 c1 | c2 | c32 | c34 | c38 | \
15600 clipper | \
15601 cris | \
15602 d30v | \
15603 elxsi | \
15604 fr30 | \
15605 h8300 | \
15606 i?86 | x86_64 | \
15607 i860 | \
15608 ia64 | \
15609 m32r | \
15610 m68* | \
15611 m88k | \
15612 mcore | \
15613 mips* | \
15614 mmix | \
15615 mn10200 | \
15616 mn10300 | \
15617 ns32k | \
15618 pdp11 | \
15619 pj* | \
15620 powerpc* | rs6000 | \
15621 romp | \
15622 s390* | \
15623 sh* | \
15624 sparc* | \
15625 v850 | \
15626 vax | \
15627 xtensa)
15628 sv_cv_stack_direction=-1 ;;
15629 c4x | \
15630 dsp16xx | \
15631 i960 | \
15632 hppa* | parisc* | \
15633 stormy16 | \
15634 we32k)
15635 sv_cv_stack_direction=1 ;;
15637 if test $cross_compiling = no; then
15638 cat > conftest.c <<EOF
15639 #include <stdio.h>
15641 get_stack_direction ()
15643 auto char dummy;
15644 static char *dummyaddr = (char *)0;
15645 if (dummyaddr != (char *)0)
15646 return &dummy > dummyaddr ? 1 : &dummy < dummyaddr ? -1 : 0;
15647 else
15649 dummyaddr = &dummy;
15651 int result = get_stack_direction ();
15652 /* The next assignment avoids tail recursion elimination
15653 (IRIX 6.4 CC). */
15654 dummyaddr = (char *)0;
15655 return result;
15660 main ()
15662 printf ("%d\n", get_stack_direction ());
15663 return 0;
15666 { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15667 (eval $ac_link) 2>&5
15668 ac_status=$?
15669 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15670 (exit $ac_status); }
15671 sv_cv_stack_direction=`./conftest`
15672 else
15673 sv_cv_stack_direction=0
15676 esac
15677 case $sv_cv_stack_direction in
15678 1) sv_cv_stack_direction_msg="grows up";;
15679 -1) sv_cv_stack_direction_msg="grows down";;
15680 *) sv_cv_stack_direction_msg="unknown";;
15681 esac
15684 { $as_echo "$as_me:$LINENO: result: $sv_cv_stack_direction_msg" >&5
15685 $as_echo "$sv_cv_stack_direction_msg" >&6; }
15687 cat >>confdefs.h <<_ACEOF
15688 #define STACK_DIRECTION $sv_cv_stack_direction
15689 _ACEOF
15692 { $as_echo "$as_me:$LINENO: checking for PIOCMAP in sys/procfs.h" >&5
15693 $as_echo_n "checking for PIOCMAP in sys/procfs.h... " >&6; }
15694 if test "${sv_cv_procfsvma+set}" = set; then
15695 $as_echo_n "(cached) " >&6
15696 else
15698 cat >conftest.$ac_ext <<_ACEOF
15699 /* confdefs.h. */
15700 _ACEOF
15701 cat confdefs.h >>conftest.$ac_ext
15702 cat >>conftest.$ac_ext <<_ACEOF
15703 /* end confdefs.h. */
15704 #include <sys/procfs.h>
15706 main ()
15708 int x = PIOCNMAP + PIOCMAP; prmap_t y;
15710 return 0;
15712 _ACEOF
15713 rm -f conftest.$ac_objext conftest$ac_exeext
15714 if { (ac_try="$ac_link"
15715 case "(($ac_try" in
15716 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15717 *) ac_try_echo=$ac_try;;
15718 esac
15719 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15720 $as_echo "$ac_try_echo") >&5
15721 (eval "$ac_link") 2>conftest.er1
15722 ac_status=$?
15723 grep -v '^ *+' conftest.er1 >conftest.err
15724 rm -f conftest.er1
15725 cat conftest.err >&5
15726 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15727 (exit $ac_status); } && {
15728 test -z "$ac_c_werror_flag" ||
15729 test ! -s conftest.err
15730 } && test -s conftest$ac_exeext && {
15731 test "$cross_compiling" = yes ||
15732 $as_test_x conftest$ac_exeext
15733 }; then
15734 sv_cv_procfsvma=yes
15735 else
15736 $as_echo "$as_me: failed program was:" >&5
15737 sed 's/^/| /' conftest.$ac_ext >&5
15739 sv_cv_procfsvma=no
15742 rm -rf conftest.dSYM
15743 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15744 conftest$ac_exeext conftest.$ac_ext
15747 { $as_echo "$as_me:$LINENO: result: $sv_cv_procfsvma" >&5
15748 $as_echo "$sv_cv_procfsvma" >&6; }
15750 for ac_func in mincore
15752 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15753 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
15754 $as_echo_n "checking for $ac_func... " >&6; }
15755 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
15756 $as_echo_n "(cached) " >&6
15757 else
15758 cat >conftest.$ac_ext <<_ACEOF
15759 /* confdefs.h. */
15760 _ACEOF
15761 cat confdefs.h >>conftest.$ac_ext
15762 cat >>conftest.$ac_ext <<_ACEOF
15763 /* end confdefs.h. */
15764 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15765 For example, HP-UX 11i <limits.h> declares gettimeofday. */
15766 #define $ac_func innocuous_$ac_func
15768 /* System header to define __stub macros and hopefully few prototypes,
15769 which can conflict with char $ac_func (); below.
15770 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15771 <limits.h> exists even on freestanding compilers. */
15773 #ifdef __STDC__
15774 # include <limits.h>
15775 #else
15776 # include <assert.h>
15777 #endif
15779 #undef $ac_func
15781 /* Override any GCC internal prototype to avoid an error.
15782 Use char because int might match the return type of a GCC
15783 builtin and then its argument prototype would still apply. */
15784 #ifdef __cplusplus
15785 extern "C"
15786 #endif
15787 char $ac_func ();
15788 /* The GNU C library defines this for functions which it implements
15789 to always fail with ENOSYS. Some functions are actually named
15790 something starting with __ and the normal name is an alias. */
15791 #if defined __stub_$ac_func || defined __stub___$ac_func
15792 choke me
15793 #endif
15796 main ()
15798 return $ac_func ();
15800 return 0;
15802 _ACEOF
15803 rm -f conftest.$ac_objext conftest$ac_exeext
15804 if { (ac_try="$ac_link"
15805 case "(($ac_try" in
15806 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15807 *) ac_try_echo=$ac_try;;
15808 esac
15809 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15810 $as_echo "$ac_try_echo") >&5
15811 (eval "$ac_link") 2>conftest.er1
15812 ac_status=$?
15813 grep -v '^ *+' conftest.er1 >conftest.err
15814 rm -f conftest.er1
15815 cat conftest.err >&5
15816 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15817 (exit $ac_status); } && {
15818 test -z "$ac_c_werror_flag" ||
15819 test ! -s conftest.err
15820 } && test -s conftest$ac_exeext && {
15821 test "$cross_compiling" = yes ||
15822 $as_test_x conftest$ac_exeext
15823 }; then
15824 eval "$as_ac_var=yes"
15825 else
15826 $as_echo "$as_me: failed program was:" >&5
15827 sed 's/^/| /' conftest.$ac_ext >&5
15829 eval "$as_ac_var=no"
15832 rm -rf conftest.dSYM
15833 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15834 conftest$ac_exeext conftest.$ac_ext
15836 ac_res=`eval 'as_val=${'$as_ac_var'}
15837 $as_echo "$as_val"'`
15838 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
15839 $as_echo "$ac_res" >&6; }
15840 as_val=`eval 'as_val=${'$as_ac_var'}
15841 $as_echo "$as_val"'`
15842 if test "x$as_val" = x""yes; then
15843 cat >>confdefs.h <<_ACEOF
15844 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15845 _ACEOF
15848 done
15850 CFG_STACKVMA=
15851 if test $sv_cv_procfsvma = yes; then
15852 CFG_STACKVMA=stackvma-procfs.c
15853 else
15854 case "$host_os" in
15855 linux*) CFG_STACKVMA=stackvma-linux.c ;;
15856 freebsd* | dragonfly*) CFG_STACKVMA=stackvma-freebsd.c ;;
15857 beos*) CFG_STACKVMA=stackvma-beos.c ;;
15858 macos* | darwin*) CFG_STACKVMA=stackvma-mach.c ;;
15859 esac
15861 if test -z "$CFG_STACKVMA" && test $ac_cv_func_mincore = yes; then
15862 CFG_STACKVMA=stackvma-mincore.c
15864 if test -n "$CFG_STACKVMA"; then
15866 cat >>confdefs.h <<\_ACEOF
15867 #define HAVE_STACKVMA 1
15868 _ACEOF
15870 else
15871 CFG_STACKVMA=stackvma-none.c
15874 cat >>confdefs.h <<_ACEOF
15875 #define CFG_STACKVMA "$CFG_STACKVMA"
15876 _ACEOF
15882 for ac_func in getrlimit setrlimit
15884 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15885 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
15886 $as_echo_n "checking for $ac_func... " >&6; }
15887 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
15888 $as_echo_n "(cached) " >&6
15889 else
15890 cat >conftest.$ac_ext <<_ACEOF
15891 /* confdefs.h. */
15892 _ACEOF
15893 cat confdefs.h >>conftest.$ac_ext
15894 cat >>conftest.$ac_ext <<_ACEOF
15895 /* end confdefs.h. */
15896 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15897 For example, HP-UX 11i <limits.h> declares gettimeofday. */
15898 #define $ac_func innocuous_$ac_func
15900 /* System header to define __stub macros and hopefully few prototypes,
15901 which can conflict with char $ac_func (); below.
15902 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15903 <limits.h> exists even on freestanding compilers. */
15905 #ifdef __STDC__
15906 # include <limits.h>
15907 #else
15908 # include <assert.h>
15909 #endif
15911 #undef $ac_func
15913 /* Override any GCC internal prototype to avoid an error.
15914 Use char because int might match the return type of a GCC
15915 builtin and then its argument prototype would still apply. */
15916 #ifdef __cplusplus
15917 extern "C"
15918 #endif
15919 char $ac_func ();
15920 /* The GNU C library defines this for functions which it implements
15921 to always fail with ENOSYS. Some functions are actually named
15922 something starting with __ and the normal name is an alias. */
15923 #if defined __stub_$ac_func || defined __stub___$ac_func
15924 choke me
15925 #endif
15928 main ()
15930 return $ac_func ();
15932 return 0;
15934 _ACEOF
15935 rm -f conftest.$ac_objext conftest$ac_exeext
15936 if { (ac_try="$ac_link"
15937 case "(($ac_try" in
15938 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15939 *) ac_try_echo=$ac_try;;
15940 esac
15941 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15942 $as_echo "$ac_try_echo") >&5
15943 (eval "$ac_link") 2>conftest.er1
15944 ac_status=$?
15945 grep -v '^ *+' conftest.er1 >conftest.err
15946 rm -f conftest.er1
15947 cat conftest.err >&5
15948 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15949 (exit $ac_status); } && {
15950 test -z "$ac_c_werror_flag" ||
15951 test ! -s conftest.err
15952 } && test -s conftest$ac_exeext && {
15953 test "$cross_compiling" = yes ||
15954 $as_test_x conftest$ac_exeext
15955 }; then
15956 eval "$as_ac_var=yes"
15957 else
15958 $as_echo "$as_me: failed program was:" >&5
15959 sed 's/^/| /' conftest.$ac_ext >&5
15961 eval "$as_ac_var=no"
15964 rm -rf conftest.dSYM
15965 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15966 conftest$ac_exeext conftest.$ac_ext
15968 ac_res=`eval 'as_val=${'$as_ac_var'}
15969 $as_echo "$as_val"'`
15970 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
15971 $as_echo "$ac_res" >&6; }
15972 as_val=`eval 'as_val=${'$as_ac_var'}
15973 $as_echo "$as_val"'`
15974 if test "x$as_val" = x""yes; then
15975 cat >>confdefs.h <<_ACEOF
15976 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15977 _ACEOF
15980 done
15988 for ac_func in sigaltstack
15990 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15991 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
15992 $as_echo_n "checking for $ac_func... " >&6; }
15993 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
15994 $as_echo_n "(cached) " >&6
15995 else
15996 cat >conftest.$ac_ext <<_ACEOF
15997 /* confdefs.h. */
15998 _ACEOF
15999 cat confdefs.h >>conftest.$ac_ext
16000 cat >>conftest.$ac_ext <<_ACEOF
16001 /* end confdefs.h. */
16002 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16003 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16004 #define $ac_func innocuous_$ac_func
16006 /* System header to define __stub macros and hopefully few prototypes,
16007 which can conflict with char $ac_func (); below.
16008 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16009 <limits.h> exists even on freestanding compilers. */
16011 #ifdef __STDC__
16012 # include <limits.h>
16013 #else
16014 # include <assert.h>
16015 #endif
16017 #undef $ac_func
16019 /* Override any GCC internal prototype to avoid an error.
16020 Use char because int might match the return type of a GCC
16021 builtin and then its argument prototype would still apply. */
16022 #ifdef __cplusplus
16023 extern "C"
16024 #endif
16025 char $ac_func ();
16026 /* The GNU C library defines this for functions which it implements
16027 to always fail with ENOSYS. Some functions are actually named
16028 something starting with __ and the normal name is an alias. */
16029 #if defined __stub_$ac_func || defined __stub___$ac_func
16030 choke me
16031 #endif
16034 main ()
16036 return $ac_func ();
16038 return 0;
16040 _ACEOF
16041 rm -f conftest.$ac_objext conftest$ac_exeext
16042 if { (ac_try="$ac_link"
16043 case "(($ac_try" in
16044 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16045 *) ac_try_echo=$ac_try;;
16046 esac
16047 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16048 $as_echo "$ac_try_echo") >&5
16049 (eval "$ac_link") 2>conftest.er1
16050 ac_status=$?
16051 grep -v '^ *+' conftest.er1 >conftest.err
16052 rm -f conftest.er1
16053 cat conftest.err >&5
16054 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16055 (exit $ac_status); } && {
16056 test -z "$ac_c_werror_flag" ||
16057 test ! -s conftest.err
16058 } && test -s conftest$ac_exeext && {
16059 test "$cross_compiling" = yes ||
16060 $as_test_x conftest$ac_exeext
16061 }; then
16062 eval "$as_ac_var=yes"
16063 else
16064 $as_echo "$as_me: failed program was:" >&5
16065 sed 's/^/| /' conftest.$ac_ext >&5
16067 eval "$as_ac_var=no"
16070 rm -rf conftest.dSYM
16071 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16072 conftest$ac_exeext conftest.$ac_ext
16074 ac_res=`eval 'as_val=${'$as_ac_var'}
16075 $as_echo "$as_val"'`
16076 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
16077 $as_echo "$ac_res" >&6; }
16078 as_val=`eval 'as_val=${'$as_ac_var'}
16079 $as_echo "$as_val"'`
16080 if test "x$as_val" = x""yes; then
16081 cat >>confdefs.h <<_ACEOF
16082 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16083 _ACEOF
16086 done
16089 if test "$ac_cv_func_sigaltstack" = yes; then
16090 { $as_echo "$as_me:$LINENO: checking for stack_t" >&5
16091 $as_echo_n "checking for stack_t... " >&6; }
16092 if test "${ac_cv_type_stack_t+set}" = set; then
16093 $as_echo_n "(cached) " >&6
16094 else
16095 ac_cv_type_stack_t=no
16096 cat >conftest.$ac_ext <<_ACEOF
16097 /* confdefs.h. */
16098 _ACEOF
16099 cat confdefs.h >>conftest.$ac_ext
16100 cat >>conftest.$ac_ext <<_ACEOF
16101 /* end confdefs.h. */
16103 #include <signal.h>
16104 #if HAVE_SYS_SIGNAL_H
16105 # include <sys/signal.h>
16106 #endif
16110 main ()
16112 if (sizeof (stack_t))
16113 return 0;
16115 return 0;
16117 _ACEOF
16118 rm -f conftest.$ac_objext
16119 if { (ac_try="$ac_compile"
16120 case "(($ac_try" in
16121 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16122 *) ac_try_echo=$ac_try;;
16123 esac
16124 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16125 $as_echo "$ac_try_echo") >&5
16126 (eval "$ac_compile") 2>conftest.er1
16127 ac_status=$?
16128 grep -v '^ *+' conftest.er1 >conftest.err
16129 rm -f conftest.er1
16130 cat conftest.err >&5
16131 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16132 (exit $ac_status); } && {
16133 test -z "$ac_c_werror_flag" ||
16134 test ! -s conftest.err
16135 } && test -s conftest.$ac_objext; then
16136 cat >conftest.$ac_ext <<_ACEOF
16137 /* confdefs.h. */
16138 _ACEOF
16139 cat confdefs.h >>conftest.$ac_ext
16140 cat >>conftest.$ac_ext <<_ACEOF
16141 /* end confdefs.h. */
16143 #include <signal.h>
16144 #if HAVE_SYS_SIGNAL_H
16145 # include <sys/signal.h>
16146 #endif
16150 main ()
16152 if (sizeof ((stack_t)))
16153 return 0;
16155 return 0;
16157 _ACEOF
16158 rm -f conftest.$ac_objext
16159 if { (ac_try="$ac_compile"
16160 case "(($ac_try" in
16161 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16162 *) ac_try_echo=$ac_try;;
16163 esac
16164 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16165 $as_echo "$ac_try_echo") >&5
16166 (eval "$ac_compile") 2>conftest.er1
16167 ac_status=$?
16168 grep -v '^ *+' conftest.er1 >conftest.err
16169 rm -f conftest.er1
16170 cat conftest.err >&5
16171 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16172 (exit $ac_status); } && {
16173 test -z "$ac_c_werror_flag" ||
16174 test ! -s conftest.err
16175 } && test -s conftest.$ac_objext; then
16177 else
16178 $as_echo "$as_me: failed program was:" >&5
16179 sed 's/^/| /' conftest.$ac_ext >&5
16181 ac_cv_type_stack_t=yes
16184 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16185 else
16186 $as_echo "$as_me: failed program was:" >&5
16187 sed 's/^/| /' conftest.$ac_ext >&5
16192 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16194 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_stack_t" >&5
16195 $as_echo "$ac_cv_type_stack_t" >&6; }
16196 if test "x$ac_cv_type_stack_t" = x""yes; then
16198 else
16200 cat >>confdefs.h <<\_ACEOF
16201 #define stack_t struct sigaltstack
16202 _ACEOF
16209 { $as_echo "$as_me:$LINENO: checking for working sigaltstack" >&5
16210 $as_echo_n "checking for working sigaltstack... " >&6; }
16211 if test "${sv_cv_sigaltstack+set}" = set; then
16212 $as_echo_n "(cached) " >&6
16213 else
16215 if test "$ac_cv_func_sigaltstack" = yes; then
16216 case "$host_os" in
16217 macos* | darwin[6-9]* | darwin[1-9][0-9]*)
16218 # On MacOS X 10.2 or newer, just assume that if it compiles, it will
16219 # work. If we were to perform the real test, 1 Crash Report dialog
16220 # window would pop up.
16221 cat >conftest.$ac_ext <<_ACEOF
16223 /* confdefs.h. */
16224 _ACEOF
16225 cat confdefs.h >>conftest.$ac_ext
16226 cat >>conftest.$ac_ext <<_ACEOF
16227 /* end confdefs.h. */
16228 #include <signal.h>
16230 main ()
16232 int x = SA_ONSTACK; stack_t ss; sigaltstack ((stack_t*)0, &ss);
16234 return 0;
16236 _ACEOF
16237 rm -f conftest.$ac_objext conftest$ac_exeext
16238 if { (ac_try="$ac_link"
16239 case "(($ac_try" in
16240 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16241 *) ac_try_echo=$ac_try;;
16242 esac
16243 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16244 $as_echo "$ac_try_echo") >&5
16245 (eval "$ac_link") 2>conftest.er1
16246 ac_status=$?
16247 grep -v '^ *+' conftest.er1 >conftest.err
16248 rm -f conftest.er1
16249 cat conftest.err >&5
16250 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16251 (exit $ac_status); } && {
16252 test -z "$ac_c_werror_flag" ||
16253 test ! -s conftest.err
16254 } && test -s conftest$ac_exeext && {
16255 test "$cross_compiling" = yes ||
16256 $as_test_x conftest$ac_exeext
16257 }; then
16258 sv_cv_sigaltstack="guessing yes"
16259 else
16260 $as_echo "$as_me: failed program was:" >&5
16261 sed 's/^/| /' conftest.$ac_ext >&5
16263 sv_cv_sigaltstack=no
16266 rm -rf conftest.dSYM
16267 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16268 conftest$ac_exeext conftest.$ac_ext
16271 if test "$cross_compiling" = yes; then
16273 case "$host_os" in
16275 cat >conftest.$ac_ext <<_ACEOF
16277 /* confdefs.h. */
16278 _ACEOF
16279 cat confdefs.h >>conftest.$ac_ext
16280 cat >>conftest.$ac_ext <<_ACEOF
16281 /* end confdefs.h. */
16282 #include <signal.h>
16284 main ()
16286 int x = SA_ONSTACK; stack_t ss; sigaltstack ((stack_t*)0, &ss);
16288 return 0;
16290 _ACEOF
16291 rm -f conftest.$ac_objext conftest$ac_exeext
16292 if { (ac_try="$ac_link"
16293 case "(($ac_try" in
16294 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16295 *) ac_try_echo=$ac_try;;
16296 esac
16297 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16298 $as_echo "$ac_try_echo") >&5
16299 (eval "$ac_link") 2>conftest.er1
16300 ac_status=$?
16301 grep -v '^ *+' conftest.er1 >conftest.err
16302 rm -f conftest.er1
16303 cat conftest.err >&5
16304 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16305 (exit $ac_status); } && {
16306 test -z "$ac_c_werror_flag" ||
16307 test ! -s conftest.err
16308 } && test -s conftest$ac_exeext && {
16309 test "$cross_compiling" = yes ||
16310 $as_test_x conftest$ac_exeext
16311 }; then
16312 sv_cv_sigaltstack="guessing yes"
16313 else
16314 $as_echo "$as_me: failed program was:" >&5
16315 sed 's/^/| /' conftest.$ac_ext >&5
16317 sv_cv_sigaltstack=no
16320 rm -rf conftest.dSYM
16321 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16322 conftest$ac_exeext conftest.$ac_ext
16324 esac
16326 else
16327 cat >conftest.$ac_ext <<_ACEOF
16329 /* confdefs.h. */
16330 _ACEOF
16331 cat confdefs.h >>conftest.$ac_ext
16332 cat >>conftest.$ac_ext <<_ACEOF
16333 /* end confdefs.h. */
16335 #include <stdlib.h>
16336 #include <signal.h>
16337 #if HAVE_SYS_SIGNAL_H
16338 # include <sys/signal.h>
16339 #endif
16340 #if HAVE_SETRLIMIT
16341 # include <sys/types.h>
16342 # include <sys/time.h>
16343 # include <sys/resource.h>
16344 #endif
16345 #ifndef SIGSTKSZ
16346 # define SIGSTKSZ 16384
16347 #endif
16348 void stackoverflow_handler (int sig)
16350 /* If we get here, the stack overflow was caught. */
16351 exit (0);
16353 volatile int * recurse_1 (volatile int n, volatile int *p)
16355 if (n >= 0)
16356 *recurse_1 (n + 1, p) += n;
16357 return p;
16359 int recurse (volatile int n)
16361 int sum = 0;
16362 return *recurse_1 (n, &sum);
16364 int main ()
16366 char mystack[SIGSTKSZ];
16367 stack_t altstack;
16368 struct sigaction action;
16369 #if defined HAVE_SETRLIMIT && defined RLIMIT_STACK
16370 /* Before starting the endless recursion, try to be friendly to the user's
16371 machine. On some Linux 2.2.x systems, there is no stack limit for user
16372 processes at all. We don't want to kill such systems. */
16373 struct rlimit rl;
16374 rl.rlim_cur = rl.rlim_max = 0x100000; /* 1 MB */
16375 setrlimit (RLIMIT_STACK, &rl);
16376 #endif
16377 /* Install the alternate stack. */
16378 altstack.ss_sp = mystack;
16379 altstack.ss_size = sizeof (mystack);
16380 altstack.ss_flags = 0; /* no SS_DISABLE */
16381 if (sigaltstack (&altstack, NULL) < 0)
16382 exit (1);
16383 /* Install the SIGSEGV handler. */
16384 sigemptyset (&action.sa_mask);
16385 action.sa_handler = &stackoverflow_handler;
16386 action.sa_flags = SA_ONSTACK;
16387 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
16388 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
16389 /* Provoke a stack overflow. */
16390 recurse (0);
16391 exit (2);
16393 _ACEOF
16394 rm -f conftest$ac_exeext
16395 if { (ac_try="$ac_link"
16396 case "(($ac_try" in
16397 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16398 *) ac_try_echo=$ac_try;;
16399 esac
16400 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16401 $as_echo "$ac_try_echo") >&5
16402 (eval "$ac_link") 2>&5
16403 ac_status=$?
16404 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16405 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16406 { (case "(($ac_try" in
16407 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16408 *) ac_try_echo=$ac_try;;
16409 esac
16410 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16411 $as_echo "$ac_try_echo") >&5
16412 (eval "$ac_try") 2>&5
16413 ac_status=$?
16414 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16415 (exit $ac_status); }; }; then
16416 sv_cv_sigaltstack=yes
16417 else
16418 $as_echo "$as_me: program exited with status $ac_status" >&5
16419 $as_echo "$as_me: failed program was:" >&5
16420 sed 's/^/| /' conftest.$ac_ext >&5
16422 ( exit $ac_status )
16423 sv_cv_sigaltstack=no
16425 rm -rf conftest.dSYM
16426 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16431 esac
16432 else
16433 sv_cv_sigaltstack=no
16437 { $as_echo "$as_me:$LINENO: result: $sv_cv_sigaltstack" >&5
16438 $as_echo "$sv_cv_sigaltstack" >&6; }
16439 if test "$sv_cv_sigaltstack" != no; then
16441 cat >>confdefs.h <<\_ACEOF
16442 #define HAVE_WORKING_SIGALTSTACK 1
16443 _ACEOF
16446 { $as_echo "$as_me:$LINENO: checking for correct stack_t interpretation" >&5
16447 $as_echo_n "checking for correct stack_t interpretation... " >&6; }
16448 if test "${sv_cv_sigaltstack_low_base+set}" = set; then
16449 $as_echo_n "(cached) " >&6
16450 else
16452 if test "$cross_compiling" = yes; then
16454 case "$host_os" in
16455 irix5*) sv_cv_sigaltstack_low_base="no" ;;
16456 *) sv_cv_sigaltstack_low_base="guessing yes" ;;
16457 esac
16459 else
16460 cat >conftest.$ac_ext <<_ACEOF
16462 /* confdefs.h. */
16463 _ACEOF
16464 cat confdefs.h >>conftest.$ac_ext
16465 cat >>conftest.$ac_ext <<_ACEOF
16466 /* end confdefs.h. */
16468 #include <stdlib.h>
16469 #include <signal.h>
16470 #if HAVE_SYS_SIGNAL_H
16471 # include <sys/signal.h>
16472 #endif
16473 #ifndef SIGSTKSZ
16474 # define SIGSTKSZ 16384
16475 #endif
16476 volatile char *stack_lower_bound;
16477 volatile char *stack_upper_bound;
16478 static void check_stack_location (volatile char *addr)
16480 if (addr >= stack_lower_bound && addr <= stack_upper_bound)
16481 exit (0);
16482 else
16483 exit (1);
16485 static void stackoverflow_handler (int sig)
16487 char dummy;
16488 check_stack_location (&dummy);
16490 int main ()
16492 char mystack[2 * SIGSTKSZ];
16493 stack_t altstack;
16494 struct sigaction action;
16495 /* Install the alternate stack. */
16496 altstack.ss_sp = mystack + SIGSTKSZ;
16497 altstack.ss_size = SIGSTKSZ;
16498 stack_lower_bound = (char *) altstack.ss_sp;
16499 stack_upper_bound = (char *) altstack.ss_sp + altstack.ss_size - 1;
16500 altstack.ss_flags = 0; /* no SS_DISABLE */
16501 if (sigaltstack (&altstack, NULL) < 0)
16502 exit (2);
16503 /* Install the SIGSEGV handler. */
16504 sigemptyset (&action.sa_mask);
16505 action.sa_handler = &stackoverflow_handler;
16506 action.sa_flags = SA_ONSTACK;
16507 if (sigaction (SIGSEGV, &action, (struct sigaction *) NULL) < 0)
16508 exit(3);
16509 /* Provoke a SIGSEGV. */
16510 raise (SIGSEGV);
16511 exit (3);
16513 _ACEOF
16514 rm -f conftest$ac_exeext
16515 if { (ac_try="$ac_link"
16516 case "(($ac_try" in
16517 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16518 *) ac_try_echo=$ac_try;;
16519 esac
16520 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16521 $as_echo "$ac_try_echo") >&5
16522 (eval "$ac_link") 2>&5
16523 ac_status=$?
16524 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16525 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16526 { (case "(($ac_try" in
16527 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16528 *) ac_try_echo=$ac_try;;
16529 esac
16530 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16531 $as_echo "$ac_try_echo") >&5
16532 (eval "$ac_try") 2>&5
16533 ac_status=$?
16534 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16535 (exit $ac_status); }; }; then
16536 sv_cv_sigaltstack_low_base=yes
16537 else
16538 $as_echo "$as_me: program exited with status $ac_status" >&5
16539 $as_echo "$as_me: failed program was:" >&5
16540 sed 's/^/| /' conftest.$ac_ext >&5
16542 ( exit $ac_status )
16543 sv_cv_sigaltstack_low_base=no
16545 rm -rf conftest.dSYM
16546 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16552 { $as_echo "$as_me:$LINENO: result: $sv_cv_sigaltstack_low_base" >&5
16553 $as_echo "$sv_cv_sigaltstack_low_base" >&6; }
16554 if test "$sv_cv_sigaltstack_low_base" = no; then
16556 cat >>confdefs.h <<\_ACEOF
16557 #define SIGALTSTACK_SS_REVERSED 1
16558 _ACEOF
16564 { $as_echo "$as_me:$LINENO: checking if the system supports catching stack overflow" >&5
16565 $as_echo_n "checking if the system supports catching stack overflow... " >&6; }
16566 if test "${sv_cv_have_stack_overflow_recovery+set}" = set; then
16567 $as_echo_n "(cached) " >&6
16568 else
16570 if test "$CFG_MACHFAULT" != fault-none.h; then
16571 sv_cv_have_stack_overflow_recovery=yes
16572 else
16573 if test "$sv_cv_sigaltstack" != no; then
16574 sv_cv_have_stack_overflow_recovery=maybe
16575 else
16576 case "$host_os" in
16577 beos*) sv_cv_have_stack_overflow_recovery=maybe ;;
16578 mingw* | cygwin*) sv_cv_have_stack_overflow_recovery=yes ;;
16579 *) sv_cv_have_stack_overflow_recovery=no ;;
16580 esac
16583 if test $sv_cv_have_stack_overflow_recovery = maybe; then
16584 if test -n "$CFG_FAULT"; then
16585 cat >conftest.$ac_ext <<_ACEOF
16586 /* confdefs.h. */
16587 _ACEOF
16588 cat confdefs.h >>conftest.$ac_ext
16589 cat >>conftest.$ac_ext <<_ACEOF
16590 /* end confdefs.h. */
16592 #include "$srcdir/src/$CFG_FAULT"
16593 #ifdef SIGSEGV_FAULT_HANDLER_ARGLIST
16594 #ifdef SIGSEGV_FAULT_ADDRESS
16595 xyzzy
16596 #endif
16597 #endif
16599 _ACEOF
16600 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16601 $EGREP "xyzzy" >/dev/null 2>&1; then
16602 condA=true
16603 else
16604 condA=false
16606 rm -f conftest*
16608 else
16609 condA=false
16611 if test -n "$CFG_FAULT"; then
16612 cat >conftest.$ac_ext <<_ACEOF
16613 /* confdefs.h. */
16614 _ACEOF
16615 cat confdefs.h >>conftest.$ac_ext
16616 cat >>conftest.$ac_ext <<_ACEOF
16617 /* end confdefs.h. */
16619 #include "$srcdir/src/$CFG_FAULT"
16620 #ifdef SIGSEGV_FAULT_HANDLER_ARGLIST
16621 #ifdef SIGSEGV_FAULT_STACKPOINTER
16622 xyzzy
16623 #endif
16624 #endif
16626 _ACEOF
16627 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16628 $EGREP "xyzzy" >/dev/null 2>&1; then
16629 condB=true
16630 else
16631 condB=false
16633 rm -f conftest*
16635 else
16636 condB=false
16638 if test "$CFG_STACKVMA" != "stackvma-none.c"; then
16639 condC=true
16640 else
16641 condC=false
16643 if { $condA && $condB; } || { $condA && $condC; } || { $condB && $condC; }; then
16644 sv_cv_have_stack_overflow_recovery=yes
16645 else
16646 sv_cv_have_stack_overflow_recovery=no
16651 { $as_echo "$as_me:$LINENO: result: $sv_cv_have_stack_overflow_recovery" >&5
16652 $as_echo "$sv_cv_have_stack_overflow_recovery" >&6; }
16653 if test $sv_cv_have_stack_overflow_recovery != no; then
16654 HAVE_STACK_OVERFLOW_RECOVERY=1
16655 else
16656 HAVE_STACK_OVERFLOW_RECOVERY=0
16660 # How to longjmp out of a signal handler, in such a way that the
16661 # alternate signal stack remains functional.
16663 # On MacOS X 10.2 or newer, we don't need these tests, because we'll end up
16664 # using handler-macos.c anyway. If we were to perform the tests, 2 Crash Report
16665 # dialog windows would pop up.
16666 case "$host_os" in
16667 macos* | darwin[6-9]* | darwin[1-9][0-9]*) ;;
16674 { $as_echo "$as_me:$LINENO: checking whether a signal handler can be left through longjmp" >&5
16675 $as_echo_n "checking whether a signal handler can be left through longjmp... " >&6; }
16676 if test "${sv_cv_leave_handler_longjmp+set}" = set; then
16677 $as_echo_n "(cached) " >&6
16678 else
16680 if test "$cross_compiling" = yes; then
16681 case "$host" in
16682 *-*-osf[4-9]* | *-*-hpux11* | *-*-linux2.[2-9]*) sv_cv_leave_handler_longjmp=yes ;;
16683 *) sv_cv_leave_handler_longjmp="guessing no" ;;
16684 esac
16686 else
16687 cat >conftest.$ac_ext <<_ACEOF
16689 /* confdefs.h. */
16690 _ACEOF
16691 cat confdefs.h >>conftest.$ac_ext
16692 cat >>conftest.$ac_ext <<_ACEOF
16693 /* end confdefs.h. */
16695 #include <stdlib.h>
16696 #include <signal.h>
16697 #include <setjmp.h>
16699 #if HAVE_SETRLIMIT
16700 # include <sys/types.h>
16701 # include <sys/time.h>
16702 # include <sys/resource.h>
16703 #endif
16704 #ifndef SIGSTKSZ
16705 # define SIGSTKSZ 16384
16706 #endif
16707 jmp_buf mainloop;
16708 sigset_t mainsigset;
16709 int pass = 0;
16710 void stackoverflow_handler (int sig)
16712 pass++;
16713 sigprocmask (SIG_SETMASK, &mainsigset, NULL);
16715 longjmp (mainloop, pass);
16717 volatile int * recurse_1 (volatile int n, volatile int *p)
16719 if (n >= 0)
16720 *recurse_1 (n + 1, p) += n;
16721 return p;
16723 int recurse (volatile int n)
16725 int sum = 0;
16726 return *recurse_1 (n, &sum);
16728 int main ()
16730 char mystack[SIGSTKSZ];
16731 stack_t altstack;
16732 struct sigaction action;
16733 sigset_t emptyset;
16734 #if defined HAVE_SETRLIMIT && defined RLIMIT_STACK
16735 /* Before starting the endless recursion, try to be friendly to the user's
16736 machine. On some Linux 2.2.x systems, there is no stack limit for user
16737 processes at all. We don't want to kill such systems. */
16738 struct rlimit rl;
16739 rl.rlim_cur = rl.rlim_max = 0x100000; /* 1 MB */
16740 setrlimit (RLIMIT_STACK, &rl);
16741 #endif
16742 /* Install the alternate stack. */
16743 altstack.ss_sp = mystack;
16744 altstack.ss_size = sizeof (mystack);
16745 altstack.ss_flags = 0; /* no SS_DISABLE */
16746 if (sigaltstack (&altstack, NULL) < 0)
16747 exit (1);
16748 /* Install the SIGSEGV handler. */
16749 sigemptyset (&action.sa_mask);
16750 action.sa_handler = &stackoverflow_handler;
16751 action.sa_flags = SA_ONSTACK;
16752 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
16753 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
16754 /* Save the current signal mask. */
16755 sigemptyset (&emptyset);
16756 sigprocmask (SIG_BLOCK, &emptyset, &mainsigset);
16757 /* Provoke two stack overflows in a row. */
16758 if (setjmp (mainloop) < 2)
16760 recurse (0);
16761 exit (2);
16763 exit (0);
16765 _ACEOF
16766 rm -f conftest$ac_exeext
16767 if { (ac_try="$ac_link"
16768 case "(($ac_try" in
16769 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16770 *) ac_try_echo=$ac_try;;
16771 esac
16772 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16773 $as_echo "$ac_try_echo") >&5
16774 (eval "$ac_link") 2>&5
16775 ac_status=$?
16776 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16777 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16778 { (case "(($ac_try" in
16779 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16780 *) ac_try_echo=$ac_try;;
16781 esac
16782 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16783 $as_echo "$ac_try_echo") >&5
16784 (eval "$ac_try") 2>&5
16785 ac_status=$?
16786 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16787 (exit $ac_status); }; }; then
16788 sv_cv_leave_handler_longjmp=yes
16789 else
16790 $as_echo "$as_me: program exited with status $ac_status" >&5
16791 $as_echo "$as_me: failed program was:" >&5
16792 sed 's/^/| /' conftest.$ac_ext >&5
16794 ( exit $ac_status )
16795 sv_cv_leave_handler_longjmp=no
16797 rm -rf conftest.dSYM
16798 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16804 { $as_echo "$as_me:$LINENO: result: $sv_cv_leave_handler_longjmp" >&5
16805 $as_echo "$sv_cv_leave_handler_longjmp" >&6; }
16812 { $as_echo "$as_me:$LINENO: checking whether a signal handler can be left through longjmp and sigaltstack" >&5
16813 $as_echo_n "checking whether a signal handler can be left through longjmp and sigaltstack... " >&6; }
16814 if test "${sv_cv_leave_handler_longjmp_sigaltstack+set}" = set; then
16815 $as_echo_n "(cached) " >&6
16816 else
16818 if test "$cross_compiling" = yes; then
16819 case "$host" in
16820 *-*-freebsd*) sv_cv_leave_handler_longjmp_sigaltstack=yes ;;
16821 *) sv_cv_leave_handler_longjmp_sigaltstack="guessing no" ;;
16822 esac
16824 else
16825 cat >conftest.$ac_ext <<_ACEOF
16827 /* confdefs.h. */
16828 _ACEOF
16829 cat confdefs.h >>conftest.$ac_ext
16830 cat >>conftest.$ac_ext <<_ACEOF
16831 /* end confdefs.h. */
16833 #include <stdlib.h>
16834 #include <signal.h>
16835 #include <setjmp.h>
16837 #ifndef SS_ONSTACK
16838 #define SS_ONSTACK SA_ONSTACK
16839 #endif
16841 #if HAVE_SETRLIMIT
16842 # include <sys/types.h>
16843 # include <sys/time.h>
16844 # include <sys/resource.h>
16845 #endif
16846 #ifndef SIGSTKSZ
16847 # define SIGSTKSZ 16384
16848 #endif
16849 jmp_buf mainloop;
16850 sigset_t mainsigset;
16851 int pass = 0;
16852 void stackoverflow_handler (int sig)
16854 pass++;
16855 sigprocmask (SIG_SETMASK, &mainsigset, NULL);
16856 { stack_t ss;
16857 if (sigaltstack (NULL, &ss) >= 0)
16859 ss.ss_flags &= ~SS_ONSTACK;
16860 sigaltstack (&ss, NULL);
16863 longjmp (mainloop, pass);
16865 volatile int * recurse_1 (volatile int n, volatile int *p)
16867 if (n >= 0)
16868 *recurse_1 (n + 1, p) += n;
16869 return p;
16871 int recurse (volatile int n)
16873 int sum = 0;
16874 return *recurse_1 (n, &sum);
16876 int main ()
16878 char mystack[SIGSTKSZ];
16879 stack_t altstack;
16880 struct sigaction action;
16881 sigset_t emptyset;
16882 #if defined HAVE_SETRLIMIT && defined RLIMIT_STACK
16883 /* Before starting the endless recursion, try to be friendly to the user's
16884 machine. On some Linux 2.2.x systems, there is no stack limit for user
16885 processes at all. We don't want to kill such systems. */
16886 struct rlimit rl;
16887 rl.rlim_cur = rl.rlim_max = 0x100000; /* 1 MB */
16888 setrlimit (RLIMIT_STACK, &rl);
16889 #endif
16890 /* Install the alternate stack. */
16891 altstack.ss_sp = mystack;
16892 altstack.ss_size = sizeof (mystack);
16893 altstack.ss_flags = 0; /* no SS_DISABLE */
16894 if (sigaltstack (&altstack, NULL) < 0)
16895 exit (1);
16896 /* Install the SIGSEGV handler. */
16897 sigemptyset (&action.sa_mask);
16898 action.sa_handler = &stackoverflow_handler;
16899 action.sa_flags = SA_ONSTACK;
16900 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
16901 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
16902 /* Save the current signal mask. */
16903 sigemptyset (&emptyset);
16904 sigprocmask (SIG_BLOCK, &emptyset, &mainsigset);
16905 /* Provoke two stack overflows in a row. */
16906 if (setjmp (mainloop) < 2)
16908 recurse (0);
16909 exit (2);
16911 exit (0);
16913 _ACEOF
16914 rm -f conftest$ac_exeext
16915 if { (ac_try="$ac_link"
16916 case "(($ac_try" in
16917 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16918 *) ac_try_echo=$ac_try;;
16919 esac
16920 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16921 $as_echo "$ac_try_echo") >&5
16922 (eval "$ac_link") 2>&5
16923 ac_status=$?
16924 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16925 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16926 { (case "(($ac_try" in
16927 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16928 *) ac_try_echo=$ac_try;;
16929 esac
16930 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16931 $as_echo "$ac_try_echo") >&5
16932 (eval "$ac_try") 2>&5
16933 ac_status=$?
16934 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16935 (exit $ac_status); }; }; then
16936 sv_cv_leave_handler_longjmp_sigaltstack=yes
16937 else
16938 $as_echo "$as_me: program exited with status $ac_status" >&5
16939 $as_echo "$as_me: failed program was:" >&5
16940 sed 's/^/| /' conftest.$ac_ext >&5
16942 ( exit $ac_status )
16943 sv_cv_leave_handler_longjmp_sigaltstack=no
16945 rm -rf conftest.dSYM
16946 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16952 { $as_echo "$as_me:$LINENO: result: $sv_cv_leave_handler_longjmp_sigaltstack" >&5
16953 $as_echo "$sv_cv_leave_handler_longjmp_sigaltstack" >&6; }
16960 { $as_echo "$as_me:$LINENO: checking whether a signal handler can be left through longjmp and setcontext" >&5
16961 $as_echo_n "checking whether a signal handler can be left through longjmp and setcontext... " >&6; }
16962 if test "${sv_cv_leave_handler_longjmp_setcontext+set}" = set; then
16963 $as_echo_n "(cached) " >&6
16964 else
16966 if test "$cross_compiling" = yes; then
16967 case "$host" in
16968 *-*-irix* | *-*-solaris*) sv_cv_leave_handler_longjmp_setcontext=yes ;;
16969 *) sv_cv_leave_handler_longjmp_setcontext="guessing no" ;;
16970 esac
16972 else
16973 cat >conftest.$ac_ext <<_ACEOF
16975 /* confdefs.h. */
16976 _ACEOF
16977 cat confdefs.h >>conftest.$ac_ext
16978 cat >>conftest.$ac_ext <<_ACEOF
16979 /* end confdefs.h. */
16981 #include <stdlib.h>
16982 #include <signal.h>
16983 #include <setjmp.h>
16984 #include <ucontext.h>
16985 #ifndef SS_ONSTACK
16986 #define SS_ONSTACK SA_ONSTACK
16987 #endif
16989 #if HAVE_SETRLIMIT
16990 # include <sys/types.h>
16991 # include <sys/time.h>
16992 # include <sys/resource.h>
16993 #endif
16994 #ifndef SIGSTKSZ
16995 # define SIGSTKSZ 16384
16996 #endif
16997 jmp_buf mainloop;
16998 sigset_t mainsigset;
16999 int pass = 0;
17000 void stackoverflow_handler (int sig)
17002 pass++;
17003 sigprocmask (SIG_SETMASK, &mainsigset, NULL);
17004 { static int fl;
17005 static ucontext_t uc;
17006 fl = 0;
17007 if (getcontext (&uc) >= 0)
17008 if (fl == 0)
17009 if (uc.uc_stack.ss_flags & SS_ONSTACK)
17011 uc.uc_stack.ss_flags &= ~SS_ONSTACK;
17012 fl = 1;
17013 setcontext (&uc);
17016 longjmp (mainloop, pass);
17018 volatile int * recurse_1 (volatile int n, volatile int *p)
17020 if (n >= 0)
17021 *recurse_1 (n + 1, p) += n;
17022 return p;
17024 int recurse (volatile int n)
17026 int sum = 0;
17027 return *recurse_1 (n, &sum);
17029 int main ()
17031 char mystack[SIGSTKSZ];
17032 stack_t altstack;
17033 struct sigaction action;
17034 sigset_t emptyset;
17035 #if defined HAVE_SETRLIMIT && defined RLIMIT_STACK
17036 /* Before starting the endless recursion, try to be friendly to the user's
17037 machine. On some Linux 2.2.x systems, there is no stack limit for user
17038 processes at all. We don't want to kill such systems. */
17039 struct rlimit rl;
17040 rl.rlim_cur = rl.rlim_max = 0x100000; /* 1 MB */
17041 setrlimit (RLIMIT_STACK, &rl);
17042 #endif
17043 /* Install the alternate stack. */
17044 altstack.ss_sp = mystack;
17045 altstack.ss_size = sizeof (mystack);
17046 altstack.ss_flags = 0; /* no SS_DISABLE */
17047 if (sigaltstack (&altstack, NULL) < 0)
17048 exit (1);
17049 /* Install the SIGSEGV handler. */
17050 sigemptyset (&action.sa_mask);
17051 action.sa_handler = &stackoverflow_handler;
17052 action.sa_flags = SA_ONSTACK;
17053 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
17054 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
17055 /* Save the current signal mask. */
17056 sigemptyset (&emptyset);
17057 sigprocmask (SIG_BLOCK, &emptyset, &mainsigset);
17058 /* Provoke two stack overflows in a row. */
17059 if (setjmp (mainloop) < 2)
17061 recurse (0);
17062 exit (2);
17064 exit (0);
17066 _ACEOF
17067 rm -f conftest$ac_exeext
17068 if { (ac_try="$ac_link"
17069 case "(($ac_try" in
17070 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17071 *) ac_try_echo=$ac_try;;
17072 esac
17073 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17074 $as_echo "$ac_try_echo") >&5
17075 (eval "$ac_link") 2>&5
17076 ac_status=$?
17077 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17078 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17079 { (case "(($ac_try" in
17080 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17081 *) ac_try_echo=$ac_try;;
17082 esac
17083 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17084 $as_echo "$ac_try_echo") >&5
17085 (eval "$ac_try") 2>&5
17086 ac_status=$?
17087 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17088 (exit $ac_status); }; }; then
17089 sv_cv_leave_handler_longjmp_setcontext=yes
17090 else
17091 $as_echo "$as_me: program exited with status $ac_status" >&5
17092 $as_echo "$as_me: failed program was:" >&5
17093 sed 's/^/| /' conftest.$ac_ext >&5
17095 ( exit $ac_status )
17096 sv_cv_leave_handler_longjmp_setcontext=no
17098 rm -rf conftest.dSYM
17099 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17105 { $as_echo "$as_me:$LINENO: result: $sv_cv_leave_handler_longjmp_setcontext" >&5
17106 $as_echo "$sv_cv_leave_handler_longjmp_setcontext" >&6; }
17109 # End of MacOS X special casing.
17111 esac
17113 # How to siglongjmp out of a signal handler, in such a way that the
17114 # alternate signal stack remains functional.
17116 # On MacOS X 10.2 or newer, we don't need these tests, because we'll end up
17117 # using handler-macos.c anyway. If we were to perform the tests, 2 Crash Report
17118 # dialog windows would pop up.
17119 case "$host_os" in
17120 macos* | darwin[6-9]* | darwin[1-9][0-9]*) ;;
17127 { $as_echo "$as_me:$LINENO: checking whether a signal handler can be left through siglongjmp" >&5
17128 $as_echo_n "checking whether a signal handler can be left through siglongjmp... " >&6; }
17129 if test "${sv_cv_leave_handler_siglongjmp+set}" = set; then
17130 $as_echo_n "(cached) " >&6
17131 else
17133 if test "$cross_compiling" = yes; then
17134 case "$host" in
17135 *-*-osf[4-9]* | *-*-hpux11* | *-*-linux2.[2-9]* | *-*-irix* | *-*-solaris*) sv_cv_leave_handler_siglongjmp=yes ;;
17136 *) sv_cv_leave_handler_siglongjmp="guessing no" ;;
17137 esac
17139 else
17140 cat >conftest.$ac_ext <<_ACEOF
17142 /* confdefs.h. */
17143 _ACEOF
17144 cat confdefs.h >>conftest.$ac_ext
17145 cat >>conftest.$ac_ext <<_ACEOF
17146 /* end confdefs.h. */
17148 #include <stdlib.h>
17149 #include <signal.h>
17150 #include <setjmp.h>
17152 #if HAVE_SETRLIMIT
17153 # include <sys/types.h>
17154 # include <sys/time.h>
17155 # include <sys/resource.h>
17156 #endif
17157 #ifndef SIGSTKSZ
17158 # define SIGSTKSZ 16384
17159 #endif
17160 sigjmp_buf mainloop;
17161 int pass = 0;
17162 void stackoverflow_handler (int sig)
17164 pass++;
17166 siglongjmp (mainloop, pass);
17168 volatile int * recurse_1 (volatile int n, volatile int *p)
17170 if (n >= 0)
17171 *recurse_1 (n + 1, p) += n;
17172 return p;
17174 int recurse (volatile int n)
17176 int sum = 0;
17177 return *recurse_1 (n, &sum);
17179 int main ()
17181 char mystack[SIGSTKSZ];
17182 stack_t altstack;
17183 struct sigaction action;
17184 #ifdef __BEOS__
17185 /* On BeOS, this would hang, burning CPU time. Better fail than hang. */
17186 exit (1);
17187 #endif
17188 #if defined HAVE_SETRLIMIT && defined RLIMIT_STACK
17189 /* Before starting the endless recursion, try to be friendly to the user's
17190 machine. On some Linux 2.2.x systems, there is no stack limit for user
17191 processes at all. We don't want to kill such systems. */
17192 struct rlimit rl;
17193 rl.rlim_cur = rl.rlim_max = 0x100000; /* 1 MB */
17194 setrlimit (RLIMIT_STACK, &rl);
17195 #endif
17196 /* Install the alternate stack. */
17197 altstack.ss_sp = mystack;
17198 altstack.ss_size = sizeof (mystack);
17199 altstack.ss_flags = 0; /* no SS_DISABLE */
17200 if (sigaltstack (&altstack, NULL) < 0)
17201 exit (1);
17202 /* Install the SIGSEGV handler. */
17203 sigemptyset (&action.sa_mask);
17204 action.sa_handler = &stackoverflow_handler;
17205 action.sa_flags = SA_ONSTACK;
17206 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
17207 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
17208 /* Provoke two stack overflows in a row. */
17209 if (sigsetjmp (mainloop, 1) < 2)
17211 recurse (0);
17212 exit (2);
17214 exit (0);
17216 _ACEOF
17217 rm -f conftest$ac_exeext
17218 if { (ac_try="$ac_link"
17219 case "(($ac_try" in
17220 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17221 *) ac_try_echo=$ac_try;;
17222 esac
17223 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17224 $as_echo "$ac_try_echo") >&5
17225 (eval "$ac_link") 2>&5
17226 ac_status=$?
17227 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17228 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17229 { (case "(($ac_try" in
17230 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17231 *) ac_try_echo=$ac_try;;
17232 esac
17233 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17234 $as_echo "$ac_try_echo") >&5
17235 (eval "$ac_try") 2>&5
17236 ac_status=$?
17237 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17238 (exit $ac_status); }; }; then
17239 sv_cv_leave_handler_siglongjmp=yes
17240 else
17241 $as_echo "$as_me: program exited with status $ac_status" >&5
17242 $as_echo "$as_me: failed program was:" >&5
17243 sed 's/^/| /' conftest.$ac_ext >&5
17245 ( exit $ac_status )
17246 sv_cv_leave_handler_siglongjmp=no
17248 rm -rf conftest.dSYM
17249 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17255 { $as_echo "$as_me:$LINENO: result: $sv_cv_leave_handler_siglongjmp" >&5
17256 $as_echo "$sv_cv_leave_handler_siglongjmp" >&6; }
17263 { $as_echo "$as_me:$LINENO: checking whether a signal handler can be left through siglongjmp and sigaltstack" >&5
17264 $as_echo_n "checking whether a signal handler can be left through siglongjmp and sigaltstack... " >&6; }
17265 if test "${sv_cv_leave_handler_siglongjmp_sigaltstack+set}" = set; then
17266 $as_echo_n "(cached) " >&6
17267 else
17269 if test "$cross_compiling" = yes; then
17270 case "$host" in
17271 *-*-freebsd*) sv_cv_leave_handler_siglongjmp_sigaltstack=yes ;;
17272 *) sv_cv_leave_handler_siglongjmp_sigaltstack="guessing no" ;;
17273 esac
17275 else
17276 cat >conftest.$ac_ext <<_ACEOF
17278 /* confdefs.h. */
17279 _ACEOF
17280 cat confdefs.h >>conftest.$ac_ext
17281 cat >>conftest.$ac_ext <<_ACEOF
17282 /* end confdefs.h. */
17284 #include <stdlib.h>
17285 #include <signal.h>
17286 #include <setjmp.h>
17288 #ifndef SS_ONSTACK
17289 #define SS_ONSTACK SA_ONSTACK
17290 #endif
17292 #if HAVE_SETRLIMIT
17293 # include <sys/types.h>
17294 # include <sys/time.h>
17295 # include <sys/resource.h>
17296 #endif
17297 #ifndef SIGSTKSZ
17298 # define SIGSTKSZ 16384
17299 #endif
17300 sigjmp_buf mainloop;
17301 int pass = 0;
17302 void stackoverflow_handler (int sig)
17304 pass++;
17305 { stack_t ss;
17306 if (sigaltstack (NULL, &ss) >= 0)
17308 ss.ss_flags &= ~SS_ONSTACK;
17309 sigaltstack (&ss, NULL);
17312 siglongjmp (mainloop, pass);
17314 volatile int * recurse_1 (volatile int n, volatile int *p)
17316 if (n >= 0)
17317 *recurse_1 (n + 1, p) += n;
17318 return p;
17320 int recurse (volatile int n)
17322 int sum = 0;
17323 return *recurse_1 (n, &sum);
17325 int main ()
17327 char mystack[SIGSTKSZ];
17328 stack_t altstack;
17329 struct sigaction action;
17330 #ifdef __BEOS__
17331 /* On BeOS, this would hang, burning CPU time. Better fail than hang. */
17332 exit (1);
17333 #endif
17334 #if defined HAVE_SETRLIMIT && defined RLIMIT_STACK
17335 /* Before starting the endless recursion, try to be friendly to the user's
17336 machine. On some Linux 2.2.x systems, there is no stack limit for user
17337 processes at all. We don't want to kill such systems. */
17338 struct rlimit rl;
17339 rl.rlim_cur = rl.rlim_max = 0x100000; /* 1 MB */
17340 setrlimit (RLIMIT_STACK, &rl);
17341 #endif
17342 /* Install the alternate stack. */
17343 altstack.ss_sp = mystack;
17344 altstack.ss_size = sizeof (mystack);
17345 altstack.ss_flags = 0; /* no SS_DISABLE */
17346 if (sigaltstack (&altstack, NULL) < 0)
17347 exit (1);
17348 /* Install the SIGSEGV handler. */
17349 sigemptyset (&action.sa_mask);
17350 action.sa_handler = &stackoverflow_handler;
17351 action.sa_flags = SA_ONSTACK;
17352 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
17353 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
17354 /* Provoke two stack overflows in a row. */
17355 if (sigsetjmp (mainloop, 1) < 2)
17357 recurse (0);
17358 exit (2);
17360 exit (0);
17362 _ACEOF
17363 rm -f conftest$ac_exeext
17364 if { (ac_try="$ac_link"
17365 case "(($ac_try" in
17366 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17367 *) ac_try_echo=$ac_try;;
17368 esac
17369 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17370 $as_echo "$ac_try_echo") >&5
17371 (eval "$ac_link") 2>&5
17372 ac_status=$?
17373 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17374 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17375 { (case "(($ac_try" in
17376 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17377 *) ac_try_echo=$ac_try;;
17378 esac
17379 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17380 $as_echo "$ac_try_echo") >&5
17381 (eval "$ac_try") 2>&5
17382 ac_status=$?
17383 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17384 (exit $ac_status); }; }; then
17385 sv_cv_leave_handler_siglongjmp_sigaltstack=yes
17386 else
17387 $as_echo "$as_me: program exited with status $ac_status" >&5
17388 $as_echo "$as_me: failed program was:" >&5
17389 sed 's/^/| /' conftest.$ac_ext >&5
17391 ( exit $ac_status )
17392 sv_cv_leave_handler_siglongjmp_sigaltstack=no
17394 rm -rf conftest.dSYM
17395 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17401 { $as_echo "$as_me:$LINENO: result: $sv_cv_leave_handler_siglongjmp_sigaltstack" >&5
17402 $as_echo "$sv_cv_leave_handler_siglongjmp_sigaltstack" >&6; }
17409 { $as_echo "$as_me:$LINENO: checking whether a signal handler can be left through siglongjmp and setcontext" >&5
17410 $as_echo_n "checking whether a signal handler can be left through siglongjmp and setcontext... " >&6; }
17411 if test "${sv_cv_leave_handler_siglongjmp_setcontext+set}" = set; then
17412 $as_echo_n "(cached) " >&6
17413 else
17415 if test "$cross_compiling" = yes; then
17416 case "$host" in
17418 *) sv_cv_leave_handler_siglongjmp_setcontext="guessing no" ;;
17419 esac
17421 else
17422 cat >conftest.$ac_ext <<_ACEOF
17424 /* confdefs.h. */
17425 _ACEOF
17426 cat confdefs.h >>conftest.$ac_ext
17427 cat >>conftest.$ac_ext <<_ACEOF
17428 /* end confdefs.h. */
17430 #include <stdlib.h>
17431 #include <signal.h>
17432 #include <setjmp.h>
17433 #include <ucontext.h>
17434 #ifndef SS_ONSTACK
17435 #define SS_ONSTACK SA_ONSTACK
17436 #endif
17438 #if HAVE_SETRLIMIT
17439 # include <sys/types.h>
17440 # include <sys/time.h>
17441 # include <sys/resource.h>
17442 #endif
17443 #ifndef SIGSTKSZ
17444 # define SIGSTKSZ 16384
17445 #endif
17446 sigjmp_buf mainloop;
17447 int pass = 0;
17448 void stackoverflow_handler (int sig)
17450 pass++;
17451 { static int fl;
17452 static ucontext_t uc;
17453 fl = 0;
17454 if (getcontext(&uc) >= 0)
17455 if (fl == 0)
17456 if (uc.uc_stack.ss_flags & SS_ONSTACK)
17458 uc.uc_stack.ss_flags &= ~SS_ONSTACK;
17459 fl = 1;
17460 setcontext(&uc);
17463 siglongjmp (mainloop, pass);
17465 volatile int * recurse_1 (volatile int n, volatile int *p)
17467 if (n >= 0)
17468 *recurse_1 (n + 1, p) += n;
17469 return p;
17471 int recurse (volatile int n)
17473 int sum = 0;
17474 return *recurse_1 (n, &sum);
17476 int main ()
17478 char mystack[SIGSTKSZ];
17479 stack_t altstack;
17480 struct sigaction action;
17481 #ifdef __BEOS__
17482 /* On BeOS, this would hang, burning CPU time. Better fail than hang. */
17483 exit (1);
17484 #endif
17485 #if defined HAVE_SETRLIMIT && defined RLIMIT_STACK
17486 /* Before starting the endless recursion, try to be friendly to the user's
17487 machine. On some Linux 2.2.x systems, there is no stack limit for user
17488 processes at all. We don't want to kill such systems. */
17489 struct rlimit rl;
17490 rl.rlim_cur = rl.rlim_max = 0x100000; /* 1 MB */
17491 setrlimit (RLIMIT_STACK, &rl);
17492 #endif
17493 /* Install the alternate stack. */
17494 altstack.ss_sp = mystack;
17495 altstack.ss_size = sizeof (mystack);
17496 altstack.ss_flags = 0; /* no SS_DISABLE */
17497 if (sigaltstack (&altstack, NULL) < 0)
17498 exit (1);
17499 /* Install the SIGSEGV handler. */
17500 sigemptyset (&action.sa_mask);
17501 action.sa_handler = &stackoverflow_handler;
17502 action.sa_flags = SA_ONSTACK;
17503 sigaction (SIGSEGV, &action, (struct sigaction *) NULL);
17504 sigaction (SIGBUS, &action, (struct sigaction *) NULL);
17505 /* Provoke two stack overflows in a row. */
17506 if (sigsetjmp (mainloop, 1) < 2)
17508 recurse (0);
17509 exit (2);
17511 exit (0);
17513 _ACEOF
17514 rm -f conftest$ac_exeext
17515 if { (ac_try="$ac_link"
17516 case "(($ac_try" in
17517 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17518 *) ac_try_echo=$ac_try;;
17519 esac
17520 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17521 $as_echo "$ac_try_echo") >&5
17522 (eval "$ac_link") 2>&5
17523 ac_status=$?
17524 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17525 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17526 { (case "(($ac_try" in
17527 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17528 *) ac_try_echo=$ac_try;;
17529 esac
17530 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17531 $as_echo "$ac_try_echo") >&5
17532 (eval "$ac_try") 2>&5
17533 ac_status=$?
17534 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17535 (exit $ac_status); }; }; then
17536 sv_cv_leave_handler_siglongjmp_setcontext=yes
17537 else
17538 $as_echo "$as_me: program exited with status $ac_status" >&5
17539 $as_echo "$as_me: failed program was:" >&5
17540 sed 's/^/| /' conftest.$ac_ext >&5
17542 ( exit $ac_status )
17543 sv_cv_leave_handler_siglongjmp_setcontext=no
17545 rm -rf conftest.dSYM
17546 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17552 { $as_echo "$as_me:$LINENO: result: $sv_cv_leave_handler_siglongjmp_setcontext" >&5
17553 $as_echo "$sv_cv_leave_handler_siglongjmp_setcontext" >&6; }
17556 # End of MacOS X special casing.
17558 esac
17560 CFG_LEAVE=
17561 if test "$sv_cv_leave_handler_longjmp" != no; then
17562 CFG_LEAVE=leave-nop.c
17563 else
17564 if test "$sv_cv_leave_handler_longjmp_sigaltstack" != no; then
17565 CFG_LEAVE=leave-sigaltstack.c
17566 else
17567 if test "$sv_cv_leave_handler_longjmp_setcontext" != no; then
17568 CFG_LEAVE=leave-setcontext.c
17572 case "$host_os" in
17573 # On BeOS, the 6 tests fail because sigaltstack() doesn't exist.
17574 # If one uses set_signal_stack() instead of sigaltstack(), the first
17575 # test actually works. i.e. sv_cv_leave_handler_longjmp would be 'yes'.
17576 beos*) CFG_LEAVE=leave-nop.c ;;
17577 esac
17578 if test -z "$CFG_LEAVE"; then
17579 CFG_LEAVE=leave-none.c
17582 cat >>confdefs.h <<_ACEOF
17583 #define CFG_LEAVE "$CFG_LEAVE"
17584 _ACEOF
17588 case "$host_os" in
17589 mingw* | cygwin*) CFG_HANDLER=handler-win32.c ;;
17591 if test -z "$CFG_HANDLER"; then
17592 if test $sv_cv_have_sigsegv_recovery = no \
17593 && test $sv_cv_have_stack_overflow_recovery = no; then
17594 CFG_HANDLER=handler-none.c
17595 else
17596 CFG_HANDLER=handler-unix.c
17600 esac
17602 cat >>confdefs.h <<_ACEOF
17603 #define CFG_HANDLER "$CFG_HANDLER"
17604 _ACEOF
17608 { echo; echo "${term_bold}Build Parameters:${term_norm}"; } >& 6
17611 { $as_echo "$as_me:$LINENO: checking whether to activate relocatable installation" >&5
17612 $as_echo_n "checking whether to activate relocatable installation... " >&6; }
17613 # Check whether --enable-relocatable was given.
17614 if test "${enable_relocatable+set}" = set; then
17615 enableval=$enable_relocatable; if test "$enableval" != no; then
17616 RELOCATABLE=yes
17617 else
17618 RELOCATABLE=no
17621 else
17622 RELOCATABLE=no
17626 { $as_echo "$as_me:$LINENO: result: $RELOCATABLE" >&5
17627 $as_echo "$RELOCATABLE" >&6; }
17630 { echo; echo "${term_bold}Output Substitution:${term_norm}"; } >& 6
17632 ac_config_files="$ac_config_files Makefile src/Makefile src/sigsegv.h tests/Makefile"
17634 cat >confcache <<\_ACEOF
17635 # This file is a shell script that caches the results of configure
17636 # tests run on this system so they can be shared between configure
17637 # scripts and configure runs, see configure's option --config-cache.
17638 # It is not useful on other systems. If it contains results you don't
17639 # want to keep, you may remove or edit it.
17641 # config.status only pays attention to the cache file if you give it
17642 # the --recheck option to rerun configure.
17644 # `ac_cv_env_foo' variables (set or unset) will be overridden when
17645 # loading this file, other *unset* `ac_cv_foo' will be assigned the
17646 # following values.
17648 _ACEOF
17650 # The following way of writing the cache mishandles newlines in values,
17651 # but we know of no workaround that is simple, portable, and efficient.
17652 # So, we kill variables containing newlines.
17653 # Ultrix sh set writes to stderr and can't be redirected directly,
17654 # and sets the high bit in the cache file unless we assign to the vars.
17656 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
17657 eval ac_val=\$$ac_var
17658 case $ac_val in #(
17659 *${as_nl}*)
17660 case $ac_var in #(
17661 *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
17662 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
17663 esac
17664 case $ac_var in #(
17665 _ | IFS | as_nl) ;; #(
17666 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
17667 *) $as_unset $ac_var ;;
17668 esac ;;
17669 esac
17670 done
17672 (set) 2>&1 |
17673 case $as_nl`(ac_space=' '; set) 2>&1` in #(
17674 *${as_nl}ac_space=\ *)
17675 # `set' does not quote correctly, so add quotes (double-quote
17676 # substitution turns \\\\ into \\, and sed turns \\ into \).
17677 sed -n \
17678 "s/'/'\\\\''/g;
17679 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
17680 ;; #(
17682 # `set' quotes correctly as required by POSIX, so do not add quotes.
17683 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
17685 esac |
17686 sort
17688 sed '
17689 /^ac_cv_env_/b end
17690 t clear
17691 :clear
17692 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
17693 t end
17694 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
17695 :end' >>confcache
17696 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
17697 if test -w "$cache_file"; then
17698 test "x$cache_file" != "x/dev/null" &&
17699 { $as_echo "$as_me:$LINENO: updating cache $cache_file" >&5
17700 $as_echo "$as_me: updating cache $cache_file" >&6;}
17701 cat confcache >$cache_file
17702 else
17703 { $as_echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
17704 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
17707 rm -f confcache
17709 test "x$prefix" = xNONE && prefix=$ac_default_prefix
17710 # Let make expand exec_prefix.
17711 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
17713 DEFS=-DHAVE_CONFIG_H
17715 ac_libobjs=
17716 ac_ltlibobjs=
17717 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
17718 # 1. Remove the extension, and $U if already installed.
17719 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
17720 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
17721 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
17722 # will be set to the directory where LIBOBJS objects are built.
17723 ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
17724 ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
17725 done
17726 LIBOBJS=$ac_libobjs
17728 LTLIBOBJS=$ac_ltlibobjs
17731 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
17732 { { $as_echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined.
17733 Usually this means the macro was only invoked conditionally." >&5
17734 $as_echo "$as_me: error: conditional \"AMDEP\" was never defined.
17735 Usually this means the macro was only invoked conditionally." >&2;}
17736 { (exit 1); exit 1; }; }
17738 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
17739 { { $as_echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
17740 Usually this means the macro was only invoked conditionally." >&5
17741 $as_echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
17742 Usually this means the macro was only invoked conditionally." >&2;}
17743 { (exit 1); exit 1; }; }
17746 : ${CONFIG_STATUS=./config.status}
17747 ac_write_fail=0
17748 ac_clean_files_save=$ac_clean_files
17749 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
17750 { $as_echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
17751 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
17752 cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
17753 #! $SHELL
17754 # Generated by $as_me.
17755 # Run this file to recreate the current configuration.
17756 # Compiler output produced by configure, useful for debugging
17757 # configure, is in config.log if it exists.
17759 debug=false
17760 ac_cs_recheck=false
17761 ac_cs_silent=false
17762 SHELL=\${CONFIG_SHELL-$SHELL}
17763 _ACEOF
17765 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
17766 ## --------------------- ##
17767 ## M4sh Initialization. ##
17768 ## --------------------- ##
17770 # Be more Bourne compatible
17771 DUALCASE=1; export DUALCASE # for MKS sh
17772 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
17773 emulate sh
17774 NULLCMD=:
17775 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
17776 # is contrary to our usage. Disable this feature.
17777 alias -g '${1+"$@"}'='"$@"'
17778 setopt NO_GLOB_SUBST
17779 else
17780 case `(set -o) 2>/dev/null` in
17781 *posix*) set -o posix ;;
17782 esac
17789 # PATH needs CR
17790 # Avoid depending upon Character Ranges.
17791 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
17792 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
17793 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
17794 as_cr_digits='0123456789'
17795 as_cr_alnum=$as_cr_Letters$as_cr_digits
17797 as_nl='
17799 export as_nl
17800 # Printing a long string crashes Solaris 7 /usr/bin/printf.
17801 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
17802 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
17803 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
17804 if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
17805 as_echo='printf %s\n'
17806 as_echo_n='printf %s'
17807 else
17808 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
17809 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
17810 as_echo_n='/usr/ucb/echo -n'
17811 else
17812 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
17813 as_echo_n_body='eval
17814 arg=$1;
17815 case $arg in
17816 *"$as_nl"*)
17817 expr "X$arg" : "X\\(.*\\)$as_nl";
17818 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
17819 esac;
17820 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
17822 export as_echo_n_body
17823 as_echo_n='sh -c $as_echo_n_body as_echo'
17825 export as_echo_body
17826 as_echo='sh -c $as_echo_body as_echo'
17829 # The user is always right.
17830 if test "${PATH_SEPARATOR+set}" != set; then
17831 PATH_SEPARATOR=:
17832 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
17833 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
17834 PATH_SEPARATOR=';'
17838 # Support unset when possible.
17839 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
17840 as_unset=unset
17841 else
17842 as_unset=false
17846 # IFS
17847 # We need space, tab and new line, in precisely that order. Quoting is
17848 # there to prevent editors from complaining about space-tab.
17849 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
17850 # splitting by setting IFS to empty value.)
17851 IFS=" "" $as_nl"
17853 # Find who we are. Look in the path if we contain no directory separator.
17854 case $0 in
17855 *[\\/]* ) as_myself=$0 ;;
17856 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17857 for as_dir in $PATH
17859 IFS=$as_save_IFS
17860 test -z "$as_dir" && as_dir=.
17861 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
17862 done
17863 IFS=$as_save_IFS
17866 esac
17867 # We did not find ourselves, most probably we were run as `sh COMMAND'
17868 # in which case we are not to be found in the path.
17869 if test "x$as_myself" = x; then
17870 as_myself=$0
17872 if test ! -f "$as_myself"; then
17873 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
17874 { (exit 1); exit 1; }
17877 # Work around bugs in pre-3.0 UWIN ksh.
17878 for as_var in ENV MAIL MAILPATH
17879 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
17880 done
17881 PS1='$ '
17882 PS2='> '
17883 PS4='+ '
17885 # NLS nuisances.
17886 LC_ALL=C
17887 export LC_ALL
17888 LANGUAGE=C
17889 export LANGUAGE
17891 # Required to use basename.
17892 if expr a : '\(a\)' >/dev/null 2>&1 &&
17893 test "X`expr 00001 : '.*\(...\)'`" = X001; then
17894 as_expr=expr
17895 else
17896 as_expr=false
17899 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
17900 as_basename=basename
17901 else
17902 as_basename=false
17906 # Name of the executable.
17907 as_me=`$as_basename -- "$0" ||
17908 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
17909 X"$0" : 'X\(//\)$' \| \
17910 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
17911 $as_echo X/"$0" |
17912 sed '/^.*\/\([^/][^/]*\)\/*$/{
17913 s//\1/
17916 /^X\/\(\/\/\)$/{
17917 s//\1/
17920 /^X\/\(\/\).*/{
17921 s//\1/
17924 s/.*/./; q'`
17926 # CDPATH.
17927 $as_unset CDPATH
17931 as_lineno_1=$LINENO
17932 as_lineno_2=$LINENO
17933 test "x$as_lineno_1" != "x$as_lineno_2" &&
17934 test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
17936 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
17937 # uniformly replaced by the line number. The first 'sed' inserts a
17938 # line-number line after each line using $LINENO; the second 'sed'
17939 # does the real work. The second script uses 'N' to pair each
17940 # line-number line with the line containing $LINENO, and appends
17941 # trailing '-' during substitution so that $LINENO is not a special
17942 # case at line end.
17943 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
17944 # scripts with optimization help from Paolo Bonzini. Blame Lee
17945 # E. McMahon (1931-1989) for sed's syntax. :-)
17946 sed -n '
17948 /[$]LINENO/=
17949 ' <$as_myself |
17950 sed '
17951 s/[$]LINENO.*/&-/
17952 t lineno
17954 :lineno
17956 :loop
17957 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
17958 t loop
17959 s/-\n.*//
17960 ' >$as_me.lineno &&
17961 chmod +x "$as_me.lineno" ||
17962 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
17963 { (exit 1); exit 1; }; }
17965 # Don't try to exec as it changes $[0], causing all sort of problems
17966 # (the dirname of $[0] is not the place where we might find the
17967 # original and so on. Autoconf is especially sensitive to this).
17968 . "./$as_me.lineno"
17969 # Exit status is that of the last command.
17970 exit
17974 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
17975 as_dirname=dirname
17976 else
17977 as_dirname=false
17980 ECHO_C= ECHO_N= ECHO_T=
17981 case `echo -n x` in
17982 -n*)
17983 case `echo 'x\c'` in
17984 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
17985 *) ECHO_C='\c';;
17986 esac;;
17988 ECHO_N='-n';;
17989 esac
17990 if expr a : '\(a\)' >/dev/null 2>&1 &&
17991 test "X`expr 00001 : '.*\(...\)'`" = X001; then
17992 as_expr=expr
17993 else
17994 as_expr=false
17997 rm -f conf$$ conf$$.exe conf$$.file
17998 if test -d conf$$.dir; then
17999 rm -f conf$$.dir/conf$$.file
18000 else
18001 rm -f conf$$.dir
18002 mkdir conf$$.dir 2>/dev/null
18004 if (echo >conf$$.file) 2>/dev/null; then
18005 if ln -s conf$$.file conf$$ 2>/dev/null; then
18006 as_ln_s='ln -s'
18007 # ... but there are two gotchas:
18008 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
18009 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
18010 # In both cases, we have to default to `cp -p'.
18011 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
18012 as_ln_s='cp -p'
18013 elif ln conf$$.file conf$$ 2>/dev/null; then
18014 as_ln_s=ln
18015 else
18016 as_ln_s='cp -p'
18018 else
18019 as_ln_s='cp -p'
18021 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
18022 rmdir conf$$.dir 2>/dev/null
18024 if mkdir -p . 2>/dev/null; then
18025 as_mkdir_p=:
18026 else
18027 test -d ./-p && rmdir ./-p
18028 as_mkdir_p=false
18031 if test -x / >/dev/null 2>&1; then
18032 as_test_x='test -x'
18033 else
18034 if ls -dL / >/dev/null 2>&1; then
18035 as_ls_L_option=L
18036 else
18037 as_ls_L_option=
18039 as_test_x='
18040 eval sh -c '\''
18041 if test -d "$1"; then
18042 test -d "$1/.";
18043 else
18044 case $1 in
18045 -*)set "./$1";;
18046 esac;
18047 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
18048 ???[sx]*):;;*)false;;esac;fi
18049 '\'' sh
18052 as_executable_p=$as_test_x
18054 # Sed expression to map a string onto a valid CPP name.
18055 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
18057 # Sed expression to map a string onto a valid variable name.
18058 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
18061 exec 6>&1
18063 # Save the log message, to keep $[0] and so on meaningful, and to
18064 # report actual input values of CONFIG_FILES etc. instead of their
18065 # values after options handling.
18066 ac_log="
18067 This file was extended by $as_me, which was
18068 generated by GNU Autoconf 2.63. Invocation command line was
18070 CONFIG_FILES = $CONFIG_FILES
18071 CONFIG_HEADERS = $CONFIG_HEADERS
18072 CONFIG_LINKS = $CONFIG_LINKS
18073 CONFIG_COMMANDS = $CONFIG_COMMANDS
18074 $ $0 $@
18076 on `(hostname || uname -n) 2>/dev/null | sed 1q`
18079 _ACEOF
18081 case $ac_config_files in *"
18082 "*) set x $ac_config_files; shift; ac_config_files=$*;;
18083 esac
18085 case $ac_config_headers in *"
18086 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
18087 esac
18090 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18091 # Files that config.status was made for.
18092 config_files="$ac_config_files"
18093 config_headers="$ac_config_headers"
18094 config_commands="$ac_config_commands"
18096 _ACEOF
18098 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18099 ac_cs_usage="\
18100 \`$as_me' instantiates files from templates according to the
18101 current configuration.
18103 Usage: $0 [OPTION]... [FILE]...
18105 -h, --help print this help, then exit
18106 -V, --version print version number and configuration settings, then exit
18107 -q, --quiet, --silent
18108 do not print progress messages
18109 -d, --debug don't remove temporary files
18110 --recheck update $as_me by reconfiguring in the same conditions
18111 --file=FILE[:TEMPLATE]
18112 instantiate the configuration file FILE
18113 --header=FILE[:TEMPLATE]
18114 instantiate the configuration header FILE
18116 Configuration files:
18117 $config_files
18119 Configuration headers:
18120 $config_headers
18122 Configuration commands:
18123 $config_commands
18125 Report bugs to <bug-autoconf@gnu.org>."
18127 _ACEOF
18128 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18129 ac_cs_version="\\
18130 config.status
18131 configured by $0, generated by GNU Autoconf 2.63,
18132 with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
18134 Copyright (C) 2008 Free Software Foundation, Inc.
18135 This config.status script is free software; the Free Software Foundation
18136 gives unlimited permission to copy, distribute and modify it."
18138 ac_pwd='$ac_pwd'
18139 srcdir='$srcdir'
18140 INSTALL='$INSTALL'
18141 MKDIR_P='$MKDIR_P'
18142 AWK='$AWK'
18143 test -n "\$AWK" || AWK=awk
18144 _ACEOF
18146 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18147 # The default lists apply if the user does not specify any file.
18148 ac_need_defaults=:
18149 while test $# != 0
18151 case $1 in
18152 --*=*)
18153 ac_option=`expr "X$1" : 'X\([^=]*\)='`
18154 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
18155 ac_shift=:
18158 ac_option=$1
18159 ac_optarg=$2
18160 ac_shift=shift
18162 esac
18164 case $ac_option in
18165 # Handling of the options.
18166 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
18167 ac_cs_recheck=: ;;
18168 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
18169 $as_echo "$ac_cs_version"; exit ;;
18170 --debug | --debu | --deb | --de | --d | -d )
18171 debug=: ;;
18172 --file | --fil | --fi | --f )
18173 $ac_shift
18174 case $ac_optarg in
18175 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
18176 esac
18177 CONFIG_FILES="$CONFIG_FILES '$ac_optarg'"
18178 ac_need_defaults=false;;
18179 --header | --heade | --head | --hea )
18180 $ac_shift
18181 case $ac_optarg in
18182 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
18183 esac
18184 CONFIG_HEADERS="$CONFIG_HEADERS '$ac_optarg'"
18185 ac_need_defaults=false;;
18186 --he | --h)
18187 # Conflict between --help and --header
18188 { $as_echo "$as_me: error: ambiguous option: $1
18189 Try \`$0 --help' for more information." >&2
18190 { (exit 1); exit 1; }; };;
18191 --help | --hel | -h )
18192 $as_echo "$ac_cs_usage"; exit ;;
18193 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
18194 | -silent | --silent | --silen | --sile | --sil | --si | --s)
18195 ac_cs_silent=: ;;
18197 # This is an error.
18198 -*) { $as_echo "$as_me: error: unrecognized option: $1
18199 Try \`$0 --help' for more information." >&2
18200 { (exit 1); exit 1; }; } ;;
18202 *) ac_config_targets="$ac_config_targets $1"
18203 ac_need_defaults=false ;;
18205 esac
18206 shift
18207 done
18209 ac_configure_extra_args=
18211 if $ac_cs_silent; then
18212 exec 6>/dev/null
18213 ac_configure_extra_args="$ac_configure_extra_args --silent"
18216 _ACEOF
18217 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18218 if \$ac_cs_recheck; then
18219 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
18220 shift
18221 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
18222 CONFIG_SHELL='$SHELL'
18223 export CONFIG_SHELL
18224 exec "\$@"
18227 _ACEOF
18228 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18229 exec 5>>config.log
18231 echo
18232 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
18233 ## Running $as_me. ##
18234 _ASBOX
18235 $as_echo "$ac_log"
18236 } >&5
18238 _ACEOF
18239 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18241 # INIT-COMMANDS
18243 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
18246 # The HP-UX ksh and POSIX shell print the target directory to stdout
18247 # if CDPATH is set.
18248 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
18250 sed_quote_subst='$sed_quote_subst'
18251 double_quote_subst='$double_quote_subst'
18252 delay_variable_subst='$delay_variable_subst'
18253 macro_version='`$ECHO "X$macro_version" | $Xsed -e "$delay_single_quote_subst"`'
18254 macro_revision='`$ECHO "X$macro_revision" | $Xsed -e "$delay_single_quote_subst"`'
18255 enable_shared='`$ECHO "X$enable_shared" | $Xsed -e "$delay_single_quote_subst"`'
18256 enable_static='`$ECHO "X$enable_static" | $Xsed -e "$delay_single_quote_subst"`'
18257 pic_mode='`$ECHO "X$pic_mode" | $Xsed -e "$delay_single_quote_subst"`'
18258 enable_fast_install='`$ECHO "X$enable_fast_install" | $Xsed -e "$delay_single_quote_subst"`'
18259 host_alias='`$ECHO "X$host_alias" | $Xsed -e "$delay_single_quote_subst"`'
18260 host='`$ECHO "X$host" | $Xsed -e "$delay_single_quote_subst"`'
18261 host_os='`$ECHO "X$host_os" | $Xsed -e "$delay_single_quote_subst"`'
18262 build_alias='`$ECHO "X$build_alias" | $Xsed -e "$delay_single_quote_subst"`'
18263 build='`$ECHO "X$build" | $Xsed -e "$delay_single_quote_subst"`'
18264 build_os='`$ECHO "X$build_os" | $Xsed -e "$delay_single_quote_subst"`'
18265 SED='`$ECHO "X$SED" | $Xsed -e "$delay_single_quote_subst"`'
18266 Xsed='`$ECHO "X$Xsed" | $Xsed -e "$delay_single_quote_subst"`'
18267 GREP='`$ECHO "X$GREP" | $Xsed -e "$delay_single_quote_subst"`'
18268 EGREP='`$ECHO "X$EGREP" | $Xsed -e "$delay_single_quote_subst"`'
18269 FGREP='`$ECHO "X$FGREP" | $Xsed -e "$delay_single_quote_subst"`'
18270 LD='`$ECHO "X$LD" | $Xsed -e "$delay_single_quote_subst"`'
18271 NM='`$ECHO "X$NM" | $Xsed -e "$delay_single_quote_subst"`'
18272 LN_S='`$ECHO "X$LN_S" | $Xsed -e "$delay_single_quote_subst"`'
18273 max_cmd_len='`$ECHO "X$max_cmd_len" | $Xsed -e "$delay_single_quote_subst"`'
18274 ac_objext='`$ECHO "X$ac_objext" | $Xsed -e "$delay_single_quote_subst"`'
18275 exeext='`$ECHO "X$exeext" | $Xsed -e "$delay_single_quote_subst"`'
18276 lt_unset='`$ECHO "X$lt_unset" | $Xsed -e "$delay_single_quote_subst"`'
18277 lt_SP2NL='`$ECHO "X$lt_SP2NL" | $Xsed -e "$delay_single_quote_subst"`'
18278 lt_NL2SP='`$ECHO "X$lt_NL2SP" | $Xsed -e "$delay_single_quote_subst"`'
18279 reload_flag='`$ECHO "X$reload_flag" | $Xsed -e "$delay_single_quote_subst"`'
18280 reload_cmds='`$ECHO "X$reload_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18281 OBJDUMP='`$ECHO "X$OBJDUMP" | $Xsed -e "$delay_single_quote_subst"`'
18282 deplibs_check_method='`$ECHO "X$deplibs_check_method" | $Xsed -e "$delay_single_quote_subst"`'
18283 file_magic_cmd='`$ECHO "X$file_magic_cmd" | $Xsed -e "$delay_single_quote_subst"`'
18284 AR='`$ECHO "X$AR" | $Xsed -e "$delay_single_quote_subst"`'
18285 AR_FLAGS='`$ECHO "X$AR_FLAGS" | $Xsed -e "$delay_single_quote_subst"`'
18286 STRIP='`$ECHO "X$STRIP" | $Xsed -e "$delay_single_quote_subst"`'
18287 RANLIB='`$ECHO "X$RANLIB" | $Xsed -e "$delay_single_quote_subst"`'
18288 old_postinstall_cmds='`$ECHO "X$old_postinstall_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18289 old_postuninstall_cmds='`$ECHO "X$old_postuninstall_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18290 old_archive_cmds='`$ECHO "X$old_archive_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18291 CC='`$ECHO "X$CC" | $Xsed -e "$delay_single_quote_subst"`'
18292 CFLAGS='`$ECHO "X$CFLAGS" | $Xsed -e "$delay_single_quote_subst"`'
18293 compiler='`$ECHO "X$compiler" | $Xsed -e "$delay_single_quote_subst"`'
18294 GCC='`$ECHO "X$GCC" | $Xsed -e "$delay_single_quote_subst"`'
18295 lt_cv_sys_global_symbol_pipe='`$ECHO "X$lt_cv_sys_global_symbol_pipe" | $Xsed -e "$delay_single_quote_subst"`'
18296 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "X$lt_cv_sys_global_symbol_to_cdecl" | $Xsed -e "$delay_single_quote_subst"`'
18297 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "X$lt_cv_sys_global_symbol_to_c_name_address" | $Xsed -e "$delay_single_quote_subst"`'
18298 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "X$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $Xsed -e "$delay_single_quote_subst"`'
18299 objdir='`$ECHO "X$objdir" | $Xsed -e "$delay_single_quote_subst"`'
18300 SHELL='`$ECHO "X$SHELL" | $Xsed -e "$delay_single_quote_subst"`'
18301 ECHO='`$ECHO "X$ECHO" | $Xsed -e "$delay_single_quote_subst"`'
18302 MAGIC_CMD='`$ECHO "X$MAGIC_CMD" | $Xsed -e "$delay_single_quote_subst"`'
18303 lt_prog_compiler_no_builtin_flag='`$ECHO "X$lt_prog_compiler_no_builtin_flag" | $Xsed -e "$delay_single_quote_subst"`'
18304 lt_prog_compiler_wl='`$ECHO "X$lt_prog_compiler_wl" | $Xsed -e "$delay_single_quote_subst"`'
18305 lt_prog_compiler_pic='`$ECHO "X$lt_prog_compiler_pic" | $Xsed -e "$delay_single_quote_subst"`'
18306 lt_prog_compiler_static='`$ECHO "X$lt_prog_compiler_static" | $Xsed -e "$delay_single_quote_subst"`'
18307 lt_cv_prog_compiler_c_o='`$ECHO "X$lt_cv_prog_compiler_c_o" | $Xsed -e "$delay_single_quote_subst"`'
18308 need_locks='`$ECHO "X$need_locks" | $Xsed -e "$delay_single_quote_subst"`'
18309 DSYMUTIL='`$ECHO "X$DSYMUTIL" | $Xsed -e "$delay_single_quote_subst"`'
18310 NMEDIT='`$ECHO "X$NMEDIT" | $Xsed -e "$delay_single_quote_subst"`'
18311 LIPO='`$ECHO "X$LIPO" | $Xsed -e "$delay_single_quote_subst"`'
18312 OTOOL='`$ECHO "X$OTOOL" | $Xsed -e "$delay_single_quote_subst"`'
18313 OTOOL64='`$ECHO "X$OTOOL64" | $Xsed -e "$delay_single_quote_subst"`'
18314 libext='`$ECHO "X$libext" | $Xsed -e "$delay_single_quote_subst"`'
18315 shrext_cmds='`$ECHO "X$shrext_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18316 extract_expsyms_cmds='`$ECHO "X$extract_expsyms_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18317 archive_cmds_need_lc='`$ECHO "X$archive_cmds_need_lc" | $Xsed -e "$delay_single_quote_subst"`'
18318 enable_shared_with_static_runtimes='`$ECHO "X$enable_shared_with_static_runtimes" | $Xsed -e "$delay_single_quote_subst"`'
18319 export_dynamic_flag_spec='`$ECHO "X$export_dynamic_flag_spec" | $Xsed -e "$delay_single_quote_subst"`'
18320 whole_archive_flag_spec='`$ECHO "X$whole_archive_flag_spec" | $Xsed -e "$delay_single_quote_subst"`'
18321 compiler_needs_object='`$ECHO "X$compiler_needs_object" | $Xsed -e "$delay_single_quote_subst"`'
18322 old_archive_from_new_cmds='`$ECHO "X$old_archive_from_new_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18323 old_archive_from_expsyms_cmds='`$ECHO "X$old_archive_from_expsyms_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18324 archive_cmds='`$ECHO "X$archive_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18325 archive_expsym_cmds='`$ECHO "X$archive_expsym_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18326 module_cmds='`$ECHO "X$module_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18327 module_expsym_cmds='`$ECHO "X$module_expsym_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18328 with_gnu_ld='`$ECHO "X$with_gnu_ld" | $Xsed -e "$delay_single_quote_subst"`'
18329 allow_undefined_flag='`$ECHO "X$allow_undefined_flag" | $Xsed -e "$delay_single_quote_subst"`'
18330 no_undefined_flag='`$ECHO "X$no_undefined_flag" | $Xsed -e "$delay_single_quote_subst"`'
18331 hardcode_libdir_flag_spec='`$ECHO "X$hardcode_libdir_flag_spec" | $Xsed -e "$delay_single_quote_subst"`'
18332 hardcode_libdir_flag_spec_ld='`$ECHO "X$hardcode_libdir_flag_spec_ld" | $Xsed -e "$delay_single_quote_subst"`'
18333 hardcode_libdir_separator='`$ECHO "X$hardcode_libdir_separator" | $Xsed -e "$delay_single_quote_subst"`'
18334 hardcode_direct='`$ECHO "X$hardcode_direct" | $Xsed -e "$delay_single_quote_subst"`'
18335 hardcode_direct_absolute='`$ECHO "X$hardcode_direct_absolute" | $Xsed -e "$delay_single_quote_subst"`'
18336 hardcode_minus_L='`$ECHO "X$hardcode_minus_L" | $Xsed -e "$delay_single_quote_subst"`'
18337 hardcode_shlibpath_var='`$ECHO "X$hardcode_shlibpath_var" | $Xsed -e "$delay_single_quote_subst"`'
18338 hardcode_automatic='`$ECHO "X$hardcode_automatic" | $Xsed -e "$delay_single_quote_subst"`'
18339 inherit_rpath='`$ECHO "X$inherit_rpath" | $Xsed -e "$delay_single_quote_subst"`'
18340 link_all_deplibs='`$ECHO "X$link_all_deplibs" | $Xsed -e "$delay_single_quote_subst"`'
18341 fix_srcfile_path='`$ECHO "X$fix_srcfile_path" | $Xsed -e "$delay_single_quote_subst"`'
18342 always_export_symbols='`$ECHO "X$always_export_symbols" | $Xsed -e "$delay_single_quote_subst"`'
18343 export_symbols_cmds='`$ECHO "X$export_symbols_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18344 exclude_expsyms='`$ECHO "X$exclude_expsyms" | $Xsed -e "$delay_single_quote_subst"`'
18345 include_expsyms='`$ECHO "X$include_expsyms" | $Xsed -e "$delay_single_quote_subst"`'
18346 prelink_cmds='`$ECHO "X$prelink_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18347 file_list_spec='`$ECHO "X$file_list_spec" | $Xsed -e "$delay_single_quote_subst"`'
18348 variables_saved_for_relink='`$ECHO "X$variables_saved_for_relink" | $Xsed -e "$delay_single_quote_subst"`'
18349 need_lib_prefix='`$ECHO "X$need_lib_prefix" | $Xsed -e "$delay_single_quote_subst"`'
18350 need_version='`$ECHO "X$need_version" | $Xsed -e "$delay_single_quote_subst"`'
18351 version_type='`$ECHO "X$version_type" | $Xsed -e "$delay_single_quote_subst"`'
18352 runpath_var='`$ECHO "X$runpath_var" | $Xsed -e "$delay_single_quote_subst"`'
18353 shlibpath_var='`$ECHO "X$shlibpath_var" | $Xsed -e "$delay_single_quote_subst"`'
18354 shlibpath_overrides_runpath='`$ECHO "X$shlibpath_overrides_runpath" | $Xsed -e "$delay_single_quote_subst"`'
18355 libname_spec='`$ECHO "X$libname_spec" | $Xsed -e "$delay_single_quote_subst"`'
18356 library_names_spec='`$ECHO "X$library_names_spec" | $Xsed -e "$delay_single_quote_subst"`'
18357 soname_spec='`$ECHO "X$soname_spec" | $Xsed -e "$delay_single_quote_subst"`'
18358 postinstall_cmds='`$ECHO "X$postinstall_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18359 postuninstall_cmds='`$ECHO "X$postuninstall_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18360 finish_cmds='`$ECHO "X$finish_cmds" | $Xsed -e "$delay_single_quote_subst"`'
18361 finish_eval='`$ECHO "X$finish_eval" | $Xsed -e "$delay_single_quote_subst"`'
18362 hardcode_into_libs='`$ECHO "X$hardcode_into_libs" | $Xsed -e "$delay_single_quote_subst"`'
18363 sys_lib_search_path_spec='`$ECHO "X$sys_lib_search_path_spec" | $Xsed -e "$delay_single_quote_subst"`'
18364 sys_lib_dlsearch_path_spec='`$ECHO "X$sys_lib_dlsearch_path_spec" | $Xsed -e "$delay_single_quote_subst"`'
18365 hardcode_action='`$ECHO "X$hardcode_action" | $Xsed -e "$delay_single_quote_subst"`'
18366 enable_dlopen='`$ECHO "X$enable_dlopen" | $Xsed -e "$delay_single_quote_subst"`'
18367 enable_dlopen_self='`$ECHO "X$enable_dlopen_self" | $Xsed -e "$delay_single_quote_subst"`'
18368 enable_dlopen_self_static='`$ECHO "X$enable_dlopen_self_static" | $Xsed -e "$delay_single_quote_subst"`'
18369 old_striplib='`$ECHO "X$old_striplib" | $Xsed -e "$delay_single_quote_subst"`'
18370 striplib='`$ECHO "X$striplib" | $Xsed -e "$delay_single_quote_subst"`'
18372 LTCC='$LTCC'
18373 LTCFLAGS='$LTCFLAGS'
18374 compiler='$compiler_DEFAULT'
18376 # Quote evaled strings.
18377 for var in SED \
18378 GREP \
18379 EGREP \
18380 FGREP \
18381 LD \
18382 NM \
18383 LN_S \
18384 lt_SP2NL \
18385 lt_NL2SP \
18386 reload_flag \
18387 OBJDUMP \
18388 deplibs_check_method \
18389 file_magic_cmd \
18390 AR \
18391 AR_FLAGS \
18392 STRIP \
18393 RANLIB \
18394 CC \
18395 CFLAGS \
18396 compiler \
18397 lt_cv_sys_global_symbol_pipe \
18398 lt_cv_sys_global_symbol_to_cdecl \
18399 lt_cv_sys_global_symbol_to_c_name_address \
18400 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
18401 SHELL \
18402 ECHO \
18403 lt_prog_compiler_no_builtin_flag \
18404 lt_prog_compiler_wl \
18405 lt_prog_compiler_pic \
18406 lt_prog_compiler_static \
18407 lt_cv_prog_compiler_c_o \
18408 need_locks \
18409 DSYMUTIL \
18410 NMEDIT \
18411 LIPO \
18412 OTOOL \
18413 OTOOL64 \
18414 shrext_cmds \
18415 export_dynamic_flag_spec \
18416 whole_archive_flag_spec \
18417 compiler_needs_object \
18418 with_gnu_ld \
18419 allow_undefined_flag \
18420 no_undefined_flag \
18421 hardcode_libdir_flag_spec \
18422 hardcode_libdir_flag_spec_ld \
18423 hardcode_libdir_separator \
18424 fix_srcfile_path \
18425 exclude_expsyms \
18426 include_expsyms \
18427 file_list_spec \
18428 variables_saved_for_relink \
18429 libname_spec \
18430 library_names_spec \
18431 soname_spec \
18432 finish_eval \
18433 old_striplib \
18434 striplib; do
18435 case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
18436 *[\\\\\\\`\\"\\\$]*)
18437 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
18440 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
18442 esac
18443 done
18445 # Double-quote double-evaled strings.
18446 for var in reload_cmds \
18447 old_postinstall_cmds \
18448 old_postuninstall_cmds \
18449 old_archive_cmds \
18450 extract_expsyms_cmds \
18451 old_archive_from_new_cmds \
18452 old_archive_from_expsyms_cmds \
18453 archive_cmds \
18454 archive_expsym_cmds \
18455 module_cmds \
18456 module_expsym_cmds \
18457 export_symbols_cmds \
18458 prelink_cmds \
18459 postinstall_cmds \
18460 postuninstall_cmds \
18461 finish_cmds \
18462 sys_lib_search_path_spec \
18463 sys_lib_dlsearch_path_spec; do
18464 case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
18465 *[\\\\\\\`\\"\\\$]*)
18466 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
18469 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
18471 esac
18472 done
18474 # Fix-up fallback echo if it was mangled by the above quoting rules.
18475 case \$lt_ECHO in
18476 *'\\\$0 --fallback-echo"') lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\$0 --fallback-echo"\$/\$0 --fallback-echo"/'\`
18478 esac
18480 ac_aux_dir='$ac_aux_dir'
18481 xsi_shell='$xsi_shell'
18482 lt_shell_append='$lt_shell_append'
18484 # See if we are running on zsh, and set the options which allow our
18485 # commands through without removal of \ escapes INIT.
18486 if test -n "\${ZSH_VERSION+set}" ; then
18487 setopt NO_GLOB_SUBST
18491 PACKAGE='$PACKAGE'
18492 VERSION='$VERSION'
18493 TIMESTAMP='$TIMESTAMP'
18494 RM='$RM'
18495 ofile='$ofile'
18500 _ACEOF
18502 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18504 # Handling of arguments.
18505 for ac_config_target in $ac_config_targets
18507 case $ac_config_target in
18508 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
18509 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
18510 "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
18511 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
18512 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
18513 "src/sigsegv.h") CONFIG_FILES="$CONFIG_FILES src/sigsegv.h" ;;
18514 "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;;
18516 *) { { $as_echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
18517 $as_echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
18518 { (exit 1); exit 1; }; };;
18519 esac
18520 done
18523 # If the user did not use the arguments to specify the items to instantiate,
18524 # then the envvar interface is used. Set only those that are not.
18525 # We use the long form for the default assignment because of an extremely
18526 # bizarre bug on SunOS 4.1.3.
18527 if $ac_need_defaults; then
18528 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
18529 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
18530 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
18533 # Have a temporary directory for convenience. Make it in the build tree
18534 # simply because there is no reason against having it here, and in addition,
18535 # creating and moving files from /tmp can sometimes cause problems.
18536 # Hook for its removal unless debugging.
18537 # Note that there is a small window in which the directory will not be cleaned:
18538 # after its creation but before its name has been assigned to `$tmp'.
18539 $debug ||
18541 tmp=
18542 trap 'exit_status=$?
18543 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
18545 trap '{ (exit 1); exit 1; }' 1 2 13 15
18547 # Create a (secure) tmp directory for tmp files.
18550 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
18551 test -n "$tmp" && test -d "$tmp"
18552 } ||
18554 tmp=./conf$$-$RANDOM
18555 (umask 077 && mkdir "$tmp")
18556 } ||
18558 $as_echo "$as_me: cannot create a temporary directory in ." >&2
18559 { (exit 1); exit 1; }
18562 # Set up the scripts for CONFIG_FILES section.
18563 # No need to generate them if there are no CONFIG_FILES.
18564 # This happens for instance with `./config.status config.h'.
18565 if test -n "$CONFIG_FILES"; then
18568 ac_cr=' '
18569 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
18570 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
18571 ac_cs_awk_cr='\\r'
18572 else
18573 ac_cs_awk_cr=$ac_cr
18576 echo 'BEGIN {' >"$tmp/subs1.awk" &&
18577 _ACEOF
18581 echo "cat >conf$$subs.awk <<_ACEOF" &&
18582 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
18583 echo "_ACEOF"
18584 } >conf$$subs.sh ||
18585 { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
18586 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
18587 { (exit 1); exit 1; }; }
18588 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
18589 ac_delim='%!_!# '
18590 for ac_last_try in false false false false false :; do
18591 . ./conf$$subs.sh ||
18592 { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
18593 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
18594 { (exit 1); exit 1; }; }
18596 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
18597 if test $ac_delim_n = $ac_delim_num; then
18598 break
18599 elif $ac_last_try; then
18600 { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
18601 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
18602 { (exit 1); exit 1; }; }
18603 else
18604 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
18606 done
18607 rm -f conf$$subs.sh
18609 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18610 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
18611 _ACEOF
18612 sed -n '
18614 s/^/S["/; s/!.*/"]=/
18617 s/^[^!]*!//
18618 :repl
18619 t repl
18620 s/'"$ac_delim"'$//
18621 t delim
18624 s/\(.\{148\}\).*/\1/
18625 t more1
18626 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
18629 b repl
18630 :more1
18631 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
18634 s/.\{148\}//
18635 t nl
18636 :delim
18638 s/\(.\{148\}\).*/\1/
18639 t more2
18640 s/["\\]/\\&/g; s/^/"/; s/$/"/
18643 :more2
18644 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
18647 s/.\{148\}//
18648 t delim
18649 ' <conf$$subs.awk | sed '
18650 /^[^""]/{
18652 s/\n//
18654 ' >>$CONFIG_STATUS || ac_write_fail=1
18655 rm -f conf$$subs.awk
18656 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18657 _ACAWK
18658 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
18659 for (key in S) S_is_set[key] = 1
18660 FS = "\a"
18664 line = $ 0
18665 nfields = split(line, field, "@")
18666 substed = 0
18667 len = length(field[1])
18668 for (i = 2; i < nfields; i++) {
18669 key = field[i]
18670 keylen = length(key)
18671 if (S_is_set[key]) {
18672 value = S[key]
18673 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
18674 len += length(value) + length(field[++i])
18675 substed = 1
18676 } else
18677 len += 1 + keylen
18680 print line
18683 _ACAWK
18684 _ACEOF
18685 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18686 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
18687 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
18688 else
18690 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
18691 || { { $as_echo "$as_me:$LINENO: error: could not setup config files machinery" >&5
18692 $as_echo "$as_me: error: could not setup config files machinery" >&2;}
18693 { (exit 1); exit 1; }; }
18694 _ACEOF
18696 # VPATH may cause trouble with some makes, so we remove $(srcdir),
18697 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
18698 # trailing colons and then remove the whole line if VPATH becomes empty
18699 # (actually we leave an empty line to preserve line numbers).
18700 if test "x$srcdir" = x.; then
18701 ac_vpsub='/^[ ]*VPATH[ ]*=/{
18702 s/:*\$(srcdir):*/:/
18703 s/:*\${srcdir}:*/:/
18704 s/:*@srcdir@:*/:/
18705 s/^\([^=]*=[ ]*\):*/\1/
18706 s/:*$//
18707 s/^[^=]*=[ ]*$//
18711 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18712 fi # test -n "$CONFIG_FILES"
18714 # Set up the scripts for CONFIG_HEADERS section.
18715 # No need to generate them if there are no CONFIG_HEADERS.
18716 # This happens for instance with `./config.status Makefile'.
18717 if test -n "$CONFIG_HEADERS"; then
18718 cat >"$tmp/defines.awk" <<\_ACAWK ||
18719 BEGIN {
18720 _ACEOF
18722 # Transform confdefs.h into an awk script `defines.awk', embedded as
18723 # here-document in config.status, that substitutes the proper values into
18724 # config.h.in to produce config.h.
18726 # Create a delimiter string that does not exist in confdefs.h, to ease
18727 # handling of long lines.
18728 ac_delim='%!_!# '
18729 for ac_last_try in false false :; do
18730 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
18731 if test -z "$ac_t"; then
18732 break
18733 elif $ac_last_try; then
18734 { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_HEADERS" >&5
18735 $as_echo "$as_me: error: could not make $CONFIG_HEADERS" >&2;}
18736 { (exit 1); exit 1; }; }
18737 else
18738 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
18740 done
18742 # For the awk script, D is an array of macro values keyed by name,
18743 # likewise P contains macro parameters if any. Preserve backslash
18744 # newline sequences.
18746 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
18747 sed -n '
18748 s/.\{148\}/&'"$ac_delim"'/g
18749 t rset
18750 :rset
18751 s/^[ ]*#[ ]*define[ ][ ]*/ /
18752 t def
18754 :def
18755 s/\\$//
18756 t bsnl
18757 s/["\\]/\\&/g
18758 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
18759 D["\1"]=" \3"/p
18760 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
18762 :bsnl
18763 s/["\\]/\\&/g
18764 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
18765 D["\1"]=" \3\\\\\\n"\\/p
18766 t cont
18767 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
18768 t cont
18770 :cont
18772 s/.\{148\}/&'"$ac_delim"'/g
18773 t clear
18774 :clear
18775 s/\\$//
18776 t bsnlc
18777 s/["\\]/\\&/g; s/^/"/; s/$/"/p
18779 :bsnlc
18780 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
18781 b cont
18782 ' <confdefs.h | sed '
18783 s/'"$ac_delim"'/"\\\
18784 "/g' >>$CONFIG_STATUS || ac_write_fail=1
18786 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18787 for (key in D) D_is_set[key] = 1
18788 FS = "\a"
18790 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
18791 line = \$ 0
18792 split(line, arg, " ")
18793 if (arg[1] == "#") {
18794 defundef = arg[2]
18795 mac1 = arg[3]
18796 } else {
18797 defundef = substr(arg[1], 2)
18798 mac1 = arg[2]
18800 split(mac1, mac2, "(") #)
18801 macro = mac2[1]
18802 prefix = substr(line, 1, index(line, defundef) - 1)
18803 if (D_is_set[macro]) {
18804 # Preserve the white space surrounding the "#".
18805 print prefix "define", macro P[macro] D[macro]
18806 next
18807 } else {
18808 # Replace #undef with comments. This is necessary, for example,
18809 # in the case of _POSIX_SOURCE, which is predefined and required
18810 # on some systems where configure will not decide to define it.
18811 if (defundef == "undef") {
18812 print "/*", prefix defundef, macro, "*/"
18813 next
18817 { print }
18818 _ACAWK
18819 _ACEOF
18820 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18821 { { $as_echo "$as_me:$LINENO: error: could not setup config headers machinery" >&5
18822 $as_echo "$as_me: error: could not setup config headers machinery" >&2;}
18823 { (exit 1); exit 1; }; }
18824 fi # test -n "$CONFIG_HEADERS"
18827 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
18828 shift
18829 for ac_tag
18831 case $ac_tag in
18832 :[FHLC]) ac_mode=$ac_tag; continue;;
18833 esac
18834 case $ac_mode$ac_tag in
18835 :[FHL]*:*);;
18836 :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: invalid tag $ac_tag" >&5
18837 $as_echo "$as_me: error: invalid tag $ac_tag" >&2;}
18838 { (exit 1); exit 1; }; };;
18839 :[FH]-) ac_tag=-:-;;
18840 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
18841 esac
18842 ac_save_IFS=$IFS
18843 IFS=:
18844 set x $ac_tag
18845 IFS=$ac_save_IFS
18846 shift
18847 ac_file=$1
18848 shift
18850 case $ac_mode in
18851 :L) ac_source=$1;;
18852 :[FH])
18853 ac_file_inputs=
18854 for ac_f
18856 case $ac_f in
18857 -) ac_f="$tmp/stdin";;
18858 *) # Look for the file first in the build tree, then in the source tree
18859 # (if the path is not absolute). The absolute path cannot be DOS-style,
18860 # because $ac_f cannot contain `:'.
18861 test -f "$ac_f" ||
18862 case $ac_f in
18863 [\\/$]*) false;;
18864 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
18865 esac ||
18866 { { $as_echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
18867 $as_echo "$as_me: error: cannot find input file: $ac_f" >&2;}
18868 { (exit 1); exit 1; }; };;
18869 esac
18870 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
18871 ac_file_inputs="$ac_file_inputs '$ac_f'"
18872 done
18874 # Let's still pretend it is `configure' which instantiates (i.e., don't
18875 # use $as_me), people would be surprised to read:
18876 # /* config.h. Generated by config.status. */
18877 configure_input='Generated from '`
18878 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
18879 `' by configure.'
18880 if test x"$ac_file" != x-; then
18881 configure_input="$ac_file. $configure_input"
18882 { $as_echo "$as_me:$LINENO: creating $ac_file" >&5
18883 $as_echo "$as_me: creating $ac_file" >&6;}
18885 # Neutralize special characters interpreted by sed in replacement strings.
18886 case $configure_input in #(
18887 *\&* | *\|* | *\\* )
18888 ac_sed_conf_input=`$as_echo "$configure_input" |
18889 sed 's/[\\\\&|]/\\\\&/g'`;; #(
18890 *) ac_sed_conf_input=$configure_input;;
18891 esac
18893 case $ac_tag in
18894 *:-:* | *:-) cat >"$tmp/stdin" \
18895 || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
18896 $as_echo "$as_me: error: could not create $ac_file" >&2;}
18897 { (exit 1); exit 1; }; } ;;
18898 esac
18900 esac
18902 ac_dir=`$as_dirname -- "$ac_file" ||
18903 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
18904 X"$ac_file" : 'X\(//\)[^/]' \| \
18905 X"$ac_file" : 'X\(//\)$' \| \
18906 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
18907 $as_echo X"$ac_file" |
18908 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
18909 s//\1/
18912 /^X\(\/\/\)[^/].*/{
18913 s//\1/
18916 /^X\(\/\/\)$/{
18917 s//\1/
18920 /^X\(\/\).*/{
18921 s//\1/
18924 s/.*/./; q'`
18925 { as_dir="$ac_dir"
18926 case $as_dir in #(
18927 -*) as_dir=./$as_dir;;
18928 esac
18929 test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
18930 as_dirs=
18931 while :; do
18932 case $as_dir in #(
18933 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
18934 *) as_qdir=$as_dir;;
18935 esac
18936 as_dirs="'$as_qdir' $as_dirs"
18937 as_dir=`$as_dirname -- "$as_dir" ||
18938 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
18939 X"$as_dir" : 'X\(//\)[^/]' \| \
18940 X"$as_dir" : 'X\(//\)$' \| \
18941 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
18942 $as_echo X"$as_dir" |
18943 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
18944 s//\1/
18947 /^X\(\/\/\)[^/].*/{
18948 s//\1/
18951 /^X\(\/\/\)$/{
18952 s//\1/
18955 /^X\(\/\).*/{
18956 s//\1/
18959 s/.*/./; q'`
18960 test -d "$as_dir" && break
18961 done
18962 test -z "$as_dirs" || eval "mkdir $as_dirs"
18963 } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
18964 $as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
18965 { (exit 1); exit 1; }; }; }
18966 ac_builddir=.
18968 case "$ac_dir" in
18969 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
18971 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
18972 # A ".." for each directory in $ac_dir_suffix.
18973 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
18974 case $ac_top_builddir_sub in
18975 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
18976 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
18977 esac ;;
18978 esac
18979 ac_abs_top_builddir=$ac_pwd
18980 ac_abs_builddir=$ac_pwd$ac_dir_suffix
18981 # for backward compatibility:
18982 ac_top_builddir=$ac_top_build_prefix
18984 case $srcdir in
18985 .) # We are building in place.
18986 ac_srcdir=.
18987 ac_top_srcdir=$ac_top_builddir_sub
18988 ac_abs_top_srcdir=$ac_pwd ;;
18989 [\\/]* | ?:[\\/]* ) # Absolute name.
18990 ac_srcdir=$srcdir$ac_dir_suffix;
18991 ac_top_srcdir=$srcdir
18992 ac_abs_top_srcdir=$srcdir ;;
18993 *) # Relative name.
18994 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
18995 ac_top_srcdir=$ac_top_build_prefix$srcdir
18996 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
18997 esac
18998 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
19001 case $ac_mode in
19004 # CONFIG_FILE
19007 case $INSTALL in
19008 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
19009 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
19010 esac
19011 ac_MKDIR_P=$MKDIR_P
19012 case $MKDIR_P in
19013 [\\/$]* | ?:[\\/]* ) ;;
19014 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
19015 esac
19016 _ACEOF
19018 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19019 # If the template does not know about datarootdir, expand it.
19020 # FIXME: This hack should be removed a few years after 2.60.
19021 ac_datarootdir_hack=; ac_datarootdir_seen=
19023 ac_sed_dataroot='
19024 /datarootdir/ {
19028 /@datadir@/p
19029 /@docdir@/p
19030 /@infodir@/p
19031 /@localedir@/p
19032 /@mandir@/p
19034 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
19035 *datarootdir*) ac_datarootdir_seen=yes;;
19036 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
19037 { $as_echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
19038 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
19039 _ACEOF
19040 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19041 ac_datarootdir_hack='
19042 s&@datadir@&$datadir&g
19043 s&@docdir@&$docdir&g
19044 s&@infodir@&$infodir&g
19045 s&@localedir@&$localedir&g
19046 s&@mandir@&$mandir&g
19047 s&\\\${datarootdir}&$datarootdir&g' ;;
19048 esac
19049 _ACEOF
19051 # Neutralize VPATH when `$srcdir' = `.'.
19052 # Shell code in configure.ac might set extrasub.
19053 # FIXME: do we really want to maintain this feature?
19054 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19055 ac_sed_extra="$ac_vpsub
19056 $extrasub
19057 _ACEOF
19058 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19060 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
19061 s|@configure_input@|$ac_sed_conf_input|;t t
19062 s&@top_builddir@&$ac_top_builddir_sub&;t t
19063 s&@top_build_prefix@&$ac_top_build_prefix&;t t
19064 s&@srcdir@&$ac_srcdir&;t t
19065 s&@abs_srcdir@&$ac_abs_srcdir&;t t
19066 s&@top_srcdir@&$ac_top_srcdir&;t t
19067 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
19068 s&@builddir@&$ac_builddir&;t t
19069 s&@abs_builddir@&$ac_abs_builddir&;t t
19070 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
19071 s&@INSTALL@&$ac_INSTALL&;t t
19072 s&@MKDIR_P@&$ac_MKDIR_P&;t t
19073 $ac_datarootdir_hack
19075 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
19076 || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
19077 $as_echo "$as_me: error: could not create $ac_file" >&2;}
19078 { (exit 1); exit 1; }; }
19080 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
19081 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
19082 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
19083 { $as_echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
19084 which seems to be undefined. Please make sure it is defined." >&5
19085 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
19086 which seems to be undefined. Please make sure it is defined." >&2;}
19088 rm -f "$tmp/stdin"
19089 case $ac_file in
19090 -) cat "$tmp/out" && rm -f "$tmp/out";;
19091 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
19092 esac \
19093 || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
19094 $as_echo "$as_me: error: could not create $ac_file" >&2;}
19095 { (exit 1); exit 1; }; }
19099 # CONFIG_HEADER
19101 if test x"$ac_file" != x-; then
19103 $as_echo "/* $configure_input */" \
19104 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
19105 } >"$tmp/config.h" \
19106 || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
19107 $as_echo "$as_me: error: could not create $ac_file" >&2;}
19108 { (exit 1); exit 1; }; }
19109 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
19110 { $as_echo "$as_me:$LINENO: $ac_file is unchanged" >&5
19111 $as_echo "$as_me: $ac_file is unchanged" >&6;}
19112 else
19113 rm -f "$ac_file"
19114 mv "$tmp/config.h" "$ac_file" \
19115 || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
19116 $as_echo "$as_me: error: could not create $ac_file" >&2;}
19117 { (exit 1); exit 1; }; }
19119 else
19120 $as_echo "/* $configure_input */" \
19121 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
19122 || { { $as_echo "$as_me:$LINENO: error: could not create -" >&5
19123 $as_echo "$as_me: error: could not create -" >&2;}
19124 { (exit 1); exit 1; }; }
19126 # Compute "$ac_file"'s index in $config_headers.
19127 _am_arg="$ac_file"
19128 _am_stamp_count=1
19129 for _am_header in $config_headers :; do
19130 case $_am_header in
19131 $_am_arg | $_am_arg:* )
19132 break ;;
19134 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
19135 esac
19136 done
19137 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
19138 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19139 X"$_am_arg" : 'X\(//\)[^/]' \| \
19140 X"$_am_arg" : 'X\(//\)$' \| \
19141 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
19142 $as_echo X"$_am_arg" |
19143 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
19144 s//\1/
19147 /^X\(\/\/\)[^/].*/{
19148 s//\1/
19151 /^X\(\/\/\)$/{
19152 s//\1/
19155 /^X\(\/\).*/{
19156 s//\1/
19159 s/.*/./; q'`/stamp-h$_am_stamp_count
19162 :C) { $as_echo "$as_me:$LINENO: executing $ac_file commands" >&5
19163 $as_echo "$as_me: executing $ac_file commands" >&6;}
19165 esac
19168 case $ac_file$ac_mode in
19169 "depfiles":C) test x"$AMDEP_TRUE" != x"" || for mf in $CONFIG_FILES; do
19170 # Strip MF so we end up with the name of the file.
19171 mf=`echo "$mf" | sed -e 's/:.*$//'`
19172 # Check whether this is an Automake generated Makefile or not.
19173 # We used to match only the files named `Makefile.in', but
19174 # some people rename them; so instead we look at the file content.
19175 # Grep'ing the first line is not enough: some people post-process
19176 # each Makefile.in and add a new line on top of each file to say so.
19177 # Grep'ing the whole file is not good either: AIX grep has a line
19178 # limit of 2048, but all sed's we know have understand at least 4000.
19179 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
19180 dirpart=`$as_dirname -- "$mf" ||
19181 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19182 X"$mf" : 'X\(//\)[^/]' \| \
19183 X"$mf" : 'X\(//\)$' \| \
19184 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
19185 $as_echo X"$mf" |
19186 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
19187 s//\1/
19190 /^X\(\/\/\)[^/].*/{
19191 s//\1/
19194 /^X\(\/\/\)$/{
19195 s//\1/
19198 /^X\(\/\).*/{
19199 s//\1/
19202 s/.*/./; q'`
19203 else
19204 continue
19206 # Extract the definition of DEPDIR, am__include, and am__quote
19207 # from the Makefile without running `make'.
19208 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
19209 test -z "$DEPDIR" && continue
19210 am__include=`sed -n 's/^am__include = //p' < "$mf"`
19211 test -z "am__include" && continue
19212 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
19213 # When using ansi2knr, U may be empty or an underscore; expand it
19214 U=`sed -n 's/^U = //p' < "$mf"`
19215 # Find all dependency output files, they are included files with
19216 # $(DEPDIR) in their names. We invoke sed twice because it is the
19217 # simplest approach to changing $(DEPDIR) to its actual value in the
19218 # expansion.
19219 for file in `sed -n "
19220 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
19221 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
19222 # Make sure the directory exists.
19223 test -f "$dirpart/$file" && continue
19224 fdir=`$as_dirname -- "$file" ||
19225 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19226 X"$file" : 'X\(//\)[^/]' \| \
19227 X"$file" : 'X\(//\)$' \| \
19228 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
19229 $as_echo X"$file" |
19230 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
19231 s//\1/
19234 /^X\(\/\/\)[^/].*/{
19235 s//\1/
19238 /^X\(\/\/\)$/{
19239 s//\1/
19242 /^X\(\/\).*/{
19243 s//\1/
19246 s/.*/./; q'`
19247 { as_dir=$dirpart/$fdir
19248 case $as_dir in #(
19249 -*) as_dir=./$as_dir;;
19250 esac
19251 test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
19252 as_dirs=
19253 while :; do
19254 case $as_dir in #(
19255 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
19256 *) as_qdir=$as_dir;;
19257 esac
19258 as_dirs="'$as_qdir' $as_dirs"
19259 as_dir=`$as_dirname -- "$as_dir" ||
19260 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19261 X"$as_dir" : 'X\(//\)[^/]' \| \
19262 X"$as_dir" : 'X\(//\)$' \| \
19263 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
19264 $as_echo X"$as_dir" |
19265 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
19266 s//\1/
19269 /^X\(\/\/\)[^/].*/{
19270 s//\1/
19273 /^X\(\/\/\)$/{
19274 s//\1/
19277 /^X\(\/\).*/{
19278 s//\1/
19281 s/.*/./; q'`
19282 test -d "$as_dir" && break
19283 done
19284 test -z "$as_dirs" || eval "mkdir $as_dirs"
19285 } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
19286 $as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
19287 { (exit 1); exit 1; }; }; }
19288 # echo "creating $dirpart/$file"
19289 echo '# dummy' > "$dirpart/$file"
19290 done
19291 done
19293 "libtool":C)
19295 # See if we are running on zsh, and set the options which allow our
19296 # commands through without removal of \ escapes.
19297 if test -n "${ZSH_VERSION+set}" ; then
19298 setopt NO_GLOB_SUBST
19301 cfgfile="${ofile}T"
19302 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
19303 $RM "$cfgfile"
19305 cat <<_LT_EOF >> "$cfgfile"
19306 #! $SHELL
19308 # `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
19309 # Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
19310 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
19311 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
19313 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
19314 # 2006, 2007, 2008 Free Software Foundation, Inc.
19315 # Written by Gordon Matzigkeit, 1996
19317 # This file is part of GNU Libtool.
19319 # GNU Libtool is free software; you can redistribute it and/or
19320 # modify it under the terms of the GNU General Public License as
19321 # published by the Free Software Foundation; either version 2 of
19322 # the License, or (at your option) any later version.
19324 # As a special exception to the GNU General Public License,
19325 # if you distribute this file as part of a program or library that
19326 # is built using GNU Libtool, you may include this file under the
19327 # same distribution terms that you use for the rest of that program.
19329 # GNU Libtool is distributed in the hope that it will be useful,
19330 # but WITHOUT ANY WARRANTY; without even the implied warranty of
19331 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19332 # GNU General Public License for more details.
19334 # You should have received a copy of the GNU General Public License
19335 # along with GNU Libtool; see the file COPYING. If not, a copy
19336 # can be downloaded from http://www.gnu.org/licenses/gpl.html, or
19337 # obtained by writing to the Free Software Foundation, Inc.,
19338 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
19341 # The names of the tagged configurations supported by this script.
19342 available_tags=""
19344 # ### BEGIN LIBTOOL CONFIG
19346 # Which release of libtool.m4 was used?
19347 macro_version=$macro_version
19348 macro_revision=$macro_revision
19350 # Whether or not to build shared libraries.
19351 build_libtool_libs=$enable_shared
19353 # Whether or not to build static libraries.
19354 build_old_libs=$enable_static
19356 # What type of objects to build.
19357 pic_mode=$pic_mode
19359 # Whether or not to optimize for fast installation.
19360 fast_install=$enable_fast_install
19362 # The host system.
19363 host_alias=$host_alias
19364 host=$host
19365 host_os=$host_os
19367 # The build system.
19368 build_alias=$build_alias
19369 build=$build
19370 build_os=$build_os
19372 # A sed program that does not truncate output.
19373 SED=$lt_SED
19375 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
19376 Xsed="\$SED -e 1s/^X//"
19378 # A grep program that handles long lines.
19379 GREP=$lt_GREP
19381 # An ERE matcher.
19382 EGREP=$lt_EGREP
19384 # A literal string matcher.
19385 FGREP=$lt_FGREP
19387 # A BSD- or MS-compatible name lister.
19388 NM=$lt_NM
19390 # Whether we need soft or hard links.
19391 LN_S=$lt_LN_S
19393 # What is the maximum length of a command?
19394 max_cmd_len=$max_cmd_len
19396 # Object file suffix (normally "o").
19397 objext=$ac_objext
19399 # Executable file suffix (normally "").
19400 exeext=$exeext
19402 # whether the shell understands "unset".
19403 lt_unset=$lt_unset
19405 # turn spaces into newlines.
19406 SP2NL=$lt_lt_SP2NL
19408 # turn newlines into spaces.
19409 NL2SP=$lt_lt_NL2SP
19411 # How to create reloadable object files.
19412 reload_flag=$lt_reload_flag
19413 reload_cmds=$lt_reload_cmds
19415 # An object symbol dumper.
19416 OBJDUMP=$lt_OBJDUMP
19418 # Method to check whether dependent libraries are shared objects.
19419 deplibs_check_method=$lt_deplibs_check_method
19421 # Command to use when deplibs_check_method == "file_magic".
19422 file_magic_cmd=$lt_file_magic_cmd
19424 # The archiver.
19425 AR=$lt_AR
19426 AR_FLAGS=$lt_AR_FLAGS
19428 # A symbol stripping program.
19429 STRIP=$lt_STRIP
19431 # Commands used to install an old-style archive.
19432 RANLIB=$lt_RANLIB
19433 old_postinstall_cmds=$lt_old_postinstall_cmds
19434 old_postuninstall_cmds=$lt_old_postuninstall_cmds
19436 # A C compiler.
19437 LTCC=$lt_CC
19439 # LTCC compiler flags.
19440 LTCFLAGS=$lt_CFLAGS
19442 # Take the output of nm and produce a listing of raw symbols and C names.
19443 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
19445 # Transform the output of nm in a proper C declaration.
19446 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
19448 # Transform the output of nm in a C name address pair.
19449 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
19451 # Transform the output of nm in a C name address pair when lib prefix is needed.
19452 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
19454 # The name of the directory that contains temporary libtool files.
19455 objdir=$objdir
19457 # Shell to use when invoking shell scripts.
19458 SHELL=$lt_SHELL
19460 # An echo program that does not interpret backslashes.
19461 ECHO=$lt_ECHO
19463 # Used to examine libraries when file_magic_cmd begins with "file".
19464 MAGIC_CMD=$MAGIC_CMD
19466 # Must we lock files when doing compilation?
19467 need_locks=$lt_need_locks
19469 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
19470 DSYMUTIL=$lt_DSYMUTIL
19472 # Tool to change global to local symbols on Mac OS X.
19473 NMEDIT=$lt_NMEDIT
19475 # Tool to manipulate fat objects and archives on Mac OS X.
19476 LIPO=$lt_LIPO
19478 # ldd/readelf like tool for Mach-O binaries on Mac OS X.
19479 OTOOL=$lt_OTOOL
19481 # ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
19482 OTOOL64=$lt_OTOOL64
19484 # Old archive suffix (normally "a").
19485 libext=$libext
19487 # Shared library suffix (normally ".so").
19488 shrext_cmds=$lt_shrext_cmds
19490 # The commands to extract the exported symbol list from a shared archive.
19491 extract_expsyms_cmds=$lt_extract_expsyms_cmds
19493 # Variables whose values should be saved in libtool wrapper scripts and
19494 # restored at link time.
19495 variables_saved_for_relink=$lt_variables_saved_for_relink
19497 # Do we need the "lib" prefix for modules?
19498 need_lib_prefix=$need_lib_prefix
19500 # Do we need a version for libraries?
19501 need_version=$need_version
19503 # Library versioning type.
19504 version_type=$version_type
19506 # Shared library runtime path variable.
19507 runpath_var=$runpath_var
19509 # Shared library path variable.
19510 shlibpath_var=$shlibpath_var
19512 # Is shlibpath searched before the hard-coded library search path?
19513 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
19515 # Format of library name prefix.
19516 libname_spec=$lt_libname_spec
19518 # List of archive names. First name is the real one, the rest are links.
19519 # The last name is the one that the linker finds with -lNAME
19520 library_names_spec=$lt_library_names_spec
19522 # The coded name of the library, if different from the real name.
19523 soname_spec=$lt_soname_spec
19525 # Command to use after installation of a shared archive.
19526 postinstall_cmds=$lt_postinstall_cmds
19528 # Command to use after uninstallation of a shared archive.
19529 postuninstall_cmds=$lt_postuninstall_cmds
19531 # Commands used to finish a libtool library installation in a directory.
19532 finish_cmds=$lt_finish_cmds
19534 # As "finish_cmds", except a single script fragment to be evaled but
19535 # not shown.
19536 finish_eval=$lt_finish_eval
19538 # Whether we should hardcode library paths into libraries.
19539 hardcode_into_libs=$hardcode_into_libs
19541 # Compile-time system search path for libraries.
19542 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
19544 # Run-time system search path for libraries.
19545 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
19547 # Whether dlopen is supported.
19548 dlopen_support=$enable_dlopen
19550 # Whether dlopen of programs is supported.
19551 dlopen_self=$enable_dlopen_self
19553 # Whether dlopen of statically linked programs is supported.
19554 dlopen_self_static=$enable_dlopen_self_static
19556 # Commands to strip libraries.
19557 old_striplib=$lt_old_striplib
19558 striplib=$lt_striplib
19561 # The linker used to build libraries.
19562 LD=$lt_LD
19564 # Commands used to build an old-style archive.
19565 old_archive_cmds=$lt_old_archive_cmds
19567 # A language specific compiler.
19568 CC=$lt_compiler
19570 # Is the compiler the GNU compiler?
19571 with_gcc=$GCC
19573 # Compiler flag to turn off builtin functions.
19574 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
19576 # How to pass a linker flag through the compiler.
19577 wl=$lt_lt_prog_compiler_wl
19579 # Additional compiler flags for building library objects.
19580 pic_flag=$lt_lt_prog_compiler_pic
19582 # Compiler flag to prevent dynamic linking.
19583 link_static_flag=$lt_lt_prog_compiler_static
19585 # Does compiler simultaneously support -c and -o options?
19586 compiler_c_o=$lt_lt_cv_prog_compiler_c_o
19588 # Whether or not to add -lc for building shared libraries.
19589 build_libtool_need_lc=$archive_cmds_need_lc
19591 # Whether or not to disallow shared libs when runtime libs are static.
19592 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
19594 # Compiler flag to allow reflexive dlopens.
19595 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
19597 # Compiler flag to generate shared objects directly from archives.
19598 whole_archive_flag_spec=$lt_whole_archive_flag_spec
19600 # Whether the compiler copes with passing no objects directly.
19601 compiler_needs_object=$lt_compiler_needs_object
19603 # Create an old-style archive from a shared archive.
19604 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
19606 # Create a temporary old-style archive to link instead of a shared archive.
19607 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
19609 # Commands used to build a shared archive.
19610 archive_cmds=$lt_archive_cmds
19611 archive_expsym_cmds=$lt_archive_expsym_cmds
19613 # Commands used to build a loadable module if different from building
19614 # a shared archive.
19615 module_cmds=$lt_module_cmds
19616 module_expsym_cmds=$lt_module_expsym_cmds
19618 # Whether we are building with GNU ld or not.
19619 with_gnu_ld=$lt_with_gnu_ld
19621 # Flag that allows shared libraries with undefined symbols to be built.
19622 allow_undefined_flag=$lt_allow_undefined_flag
19624 # Flag that enforces no undefined symbols.
19625 no_undefined_flag=$lt_no_undefined_flag
19627 # Flag to hardcode \$libdir into a binary during linking.
19628 # This must work even if \$libdir does not exist
19629 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
19631 # If ld is used when linking, flag to hardcode \$libdir into a binary
19632 # during linking. This must work even if \$libdir does not exist.
19633 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
19635 # Whether we need a single "-rpath" flag with a separated argument.
19636 hardcode_libdir_separator=$lt_hardcode_libdir_separator
19638 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
19639 # DIR into the resulting binary.
19640 hardcode_direct=$hardcode_direct
19642 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
19643 # DIR into the resulting binary and the resulting library dependency is
19644 # "absolute",i.e impossible to change by setting \${shlibpath_var} if the
19645 # library is relocated.
19646 hardcode_direct_absolute=$hardcode_direct_absolute
19648 # Set to "yes" if using the -LDIR flag during linking hardcodes DIR
19649 # into the resulting binary.
19650 hardcode_minus_L=$hardcode_minus_L
19652 # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
19653 # into the resulting binary.
19654 hardcode_shlibpath_var=$hardcode_shlibpath_var
19656 # Set to "yes" if building a shared library automatically hardcodes DIR
19657 # into the library and all subsequent libraries and executables linked
19658 # against it.
19659 hardcode_automatic=$hardcode_automatic
19661 # Set to yes if linker adds runtime paths of dependent libraries
19662 # to runtime path list.
19663 inherit_rpath=$inherit_rpath
19665 # Whether libtool must link a program against all its dependency libraries.
19666 link_all_deplibs=$link_all_deplibs
19668 # Fix the shell variable \$srcfile for the compiler.
19669 fix_srcfile_path=$lt_fix_srcfile_path
19671 # Set to "yes" if exported symbols are required.
19672 always_export_symbols=$always_export_symbols
19674 # The commands to list exported symbols.
19675 export_symbols_cmds=$lt_export_symbols_cmds
19677 # Symbols that should not be listed in the preloaded symbols.
19678 exclude_expsyms=$lt_exclude_expsyms
19680 # Symbols that must always be exported.
19681 include_expsyms=$lt_include_expsyms
19683 # Commands necessary for linking programs (against libraries) with templates.
19684 prelink_cmds=$lt_prelink_cmds
19686 # Specify filename containing input files.
19687 file_list_spec=$lt_file_list_spec
19689 # How to hardcode a shared library path into an executable.
19690 hardcode_action=$hardcode_action
19692 # ### END LIBTOOL CONFIG
19694 _LT_EOF
19696 case $host_os in
19697 aix3*)
19698 cat <<\_LT_EOF >> "$cfgfile"
19699 # AIX sometimes has problems with the GCC collect2 program. For some
19700 # reason, if we set the COLLECT_NAMES environment variable, the problems
19701 # vanish in a puff of smoke.
19702 if test "X${COLLECT_NAMES+set}" != Xset; then
19703 COLLECT_NAMES=
19704 export COLLECT_NAMES
19706 _LT_EOF
19708 esac
19711 ltmain="$ac_aux_dir/ltmain.sh"
19714 # We use sed instead of cat because bash on DJGPP gets confused if
19715 # if finds mixed CR/LF and LF-only lines. Since sed operates in
19716 # text mode, it properly converts lines to CR/LF. This bash problem
19717 # is reportedly fixed, but why not run on old versions too?
19718 sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
19719 || (rm -f "$cfgfile"; exit 1)
19721 case $xsi_shell in
19722 yes)
19723 cat << \_LT_EOF >> "$cfgfile"
19725 # func_dirname file append nondir_replacement
19726 # Compute the dirname of FILE. If nonempty, add APPEND to the result,
19727 # otherwise set result to NONDIR_REPLACEMENT.
19728 func_dirname ()
19730 case ${1} in
19731 */*) func_dirname_result="${1%/*}${2}" ;;
19732 * ) func_dirname_result="${3}" ;;
19733 esac
19736 # func_basename file
19737 func_basename ()
19739 func_basename_result="${1##*/}"
19742 # func_dirname_and_basename file append nondir_replacement
19743 # perform func_basename and func_dirname in a single function
19744 # call:
19745 # dirname: Compute the dirname of FILE. If nonempty,
19746 # add APPEND to the result, otherwise set result
19747 # to NONDIR_REPLACEMENT.
19748 # value returned in "$func_dirname_result"
19749 # basename: Compute filename of FILE.
19750 # value retuned in "$func_basename_result"
19751 # Implementation must be kept synchronized with func_dirname
19752 # and func_basename. For efficiency, we do not delegate to
19753 # those functions but instead duplicate the functionality here.
19754 func_dirname_and_basename ()
19756 case ${1} in
19757 */*) func_dirname_result="${1%/*}${2}" ;;
19758 * ) func_dirname_result="${3}" ;;
19759 esac
19760 func_basename_result="${1##*/}"
19763 # func_stripname prefix suffix name
19764 # strip PREFIX and SUFFIX off of NAME.
19765 # PREFIX and SUFFIX must not contain globbing or regex special
19766 # characters, hashes, percent signs, but SUFFIX may contain a leading
19767 # dot (in which case that matches only a dot).
19768 func_stripname ()
19770 # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
19771 # positional parameters, so assign one to ordinary parameter first.
19772 func_stripname_result=${3}
19773 func_stripname_result=${func_stripname_result#"${1}"}
19774 func_stripname_result=${func_stripname_result%"${2}"}
19777 # func_opt_split
19778 func_opt_split ()
19780 func_opt_split_opt=${1%%=*}
19781 func_opt_split_arg=${1#*=}
19784 # func_lo2o object
19785 func_lo2o ()
19787 case ${1} in
19788 *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
19789 *) func_lo2o_result=${1} ;;
19790 esac
19793 # func_xform libobj-or-source
19794 func_xform ()
19796 func_xform_result=${1%.*}.lo
19799 # func_arith arithmetic-term...
19800 func_arith ()
19802 func_arith_result=$(( $* ))
19805 # func_len string
19806 # STRING may not start with a hyphen.
19807 func_len ()
19809 func_len_result=${#1}
19812 _LT_EOF
19814 *) # Bourne compatible functions.
19815 cat << \_LT_EOF >> "$cfgfile"
19817 # func_dirname file append nondir_replacement
19818 # Compute the dirname of FILE. If nonempty, add APPEND to the result,
19819 # otherwise set result to NONDIR_REPLACEMENT.
19820 func_dirname ()
19822 # Extract subdirectory from the argument.
19823 func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"`
19824 if test "X$func_dirname_result" = "X${1}"; then
19825 func_dirname_result="${3}"
19826 else
19827 func_dirname_result="$func_dirname_result${2}"
19831 # func_basename file
19832 func_basename ()
19834 func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"`
19838 # func_stripname prefix suffix name
19839 # strip PREFIX and SUFFIX off of NAME.
19840 # PREFIX and SUFFIX must not contain globbing or regex special
19841 # characters, hashes, percent signs, but SUFFIX may contain a leading
19842 # dot (in which case that matches only a dot).
19843 # func_strip_suffix prefix name
19844 func_stripname ()
19846 case ${2} in
19847 .*) func_stripname_result=`$ECHO "X${3}" \
19848 | $Xsed -e "s%^${1}%%" -e "s%\\\\${2}\$%%"`;;
19849 *) func_stripname_result=`$ECHO "X${3}" \
19850 | $Xsed -e "s%^${1}%%" -e "s%${2}\$%%"`;;
19851 esac
19854 # sed scripts:
19855 my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
19856 my_sed_long_arg='1s/^-[^=]*=//'
19858 # func_opt_split
19859 func_opt_split ()
19861 func_opt_split_opt=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_opt"`
19862 func_opt_split_arg=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_arg"`
19865 # func_lo2o object
19866 func_lo2o ()
19868 func_lo2o_result=`$ECHO "X${1}" | $Xsed -e "$lo2o"`
19871 # func_xform libobj-or-source
19872 func_xform ()
19874 func_xform_result=`$ECHO "X${1}" | $Xsed -e 's/\.[^.]*$/.lo/'`
19877 # func_arith arithmetic-term...
19878 func_arith ()
19880 func_arith_result=`expr "$@"`
19883 # func_len string
19884 # STRING may not start with a hyphen.
19885 func_len ()
19887 func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
19890 _LT_EOF
19891 esac
19893 case $lt_shell_append in
19894 yes)
19895 cat << \_LT_EOF >> "$cfgfile"
19897 # func_append var value
19898 # Append VALUE to the end of shell variable VAR.
19899 func_append ()
19901 eval "$1+=\$2"
19903 _LT_EOF
19906 cat << \_LT_EOF >> "$cfgfile"
19908 # func_append var value
19909 # Append VALUE to the end of shell variable VAR.
19910 func_append ()
19912 eval "$1=\$$1\$2"
19915 _LT_EOF
19917 esac
19920 sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
19921 || (rm -f "$cfgfile"; exit 1)
19923 mv -f "$cfgfile" "$ofile" ||
19924 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
19925 chmod +x "$ofile"
19929 esac
19930 done # for ac_tag
19933 { (exit 0); exit 0; }
19934 _ACEOF
19935 chmod +x $CONFIG_STATUS
19936 ac_clean_files=$ac_clean_files_save
19938 test $ac_write_fail = 0 ||
19939 { { $as_echo "$as_me:$LINENO: error: write failure creating $CONFIG_STATUS" >&5
19940 $as_echo "$as_me: error: write failure creating $CONFIG_STATUS" >&2;}
19941 { (exit 1); exit 1; }; }
19944 # configure is writing to config.log, and then calls config.status.
19945 # config.status does its own redirection, appending to config.log.
19946 # Unfortunately, on DOS this fails, as config.log is still kept open
19947 # by configure, so config.status won't be able to write to it; its
19948 # output is simply discarded. So we exec the FD to /dev/null,
19949 # effectively closing config.log, so it can be properly (re)opened and
19950 # appended to by config.status. When coming back to configure, we
19951 # need to make the FD available again.
19952 if test "$no_create" != yes; then
19953 ac_cs_success=:
19954 ac_config_status_args=
19955 test "$silent" = yes &&
19956 ac_config_status_args="$ac_config_status_args --quiet"
19957 exec 5>/dev/null
19958 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
19959 exec 5>>config.log
19960 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
19961 # would make configure fail if this is the last instruction.
19962 $ac_cs_success || { (exit 1); exit 1; }
19964 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
19965 { $as_echo "$as_me:$LINENO: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
19966 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
19970 { echo; echo "Now please type '${term_bold}make${term_norm}' to compile. Good luck."; echo; } >& 6