diff options
author | Jakub Jelinek <jakub@redhat.com> | 2004-07-15 19:38:42 +0200 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2004-07-15 19:38:42 +0200 |
commit | d5325238eb0dead53af57fbdf1a8154608513393 (patch) | |
tree | 6fa1b85ff3475a685a64dbf2267276a5d9f5319a /libstdc++-v3 | |
parent | 429b4470bd94c9a894fa65b83fc80254cfee4e7e (diff) | |
download | gcc-d5325238eb0dead53af57fbdf1a8154608513393.zip gcc-d5325238eb0dead53af57fbdf1a8154608513393.tar.gz gcc-d5325238eb0dead53af57fbdf1a8154608513393.tar.bz2 |
re PR libstdc++/14697 (libstdc++ couldn't find 32bit libgcc_s)
PR libstdc++/14697
* acinclude.m4 (glibcxx_shared_libgcc): Correct
glibcxx_shared_libgcc test for multilibs.
* configure: Rebuilt.
From-SVN: r84762
Diffstat (limited to 'libstdc++-v3')
-rw-r--r-- | libstdc++-v3/ChangeLog | 7 | ||||
-rw-r--r-- | libstdc++-v3/acinclude.m4 | 17 | ||||
-rwxr-xr-x | libstdc++-v3/configure | 64 |
3 files changed, 88 insertions, 0 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 6c8101f..39c9e3e 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,10 @@ +2004-07-15 Jakub Jelinek <jakub@redhat.com> + + PR libstdc++/14697 + * acinclude.m4 (glibcxx_shared_libgcc): Correct + glibcxx_shared_libgcc test for multilibs. + * configure: Rebuilt. + 2004-07-14 Paolo Carlini <pcarlini@suse.de> PR libstdc++/16505 diff --git a/libstdc++-v3/acinclude.m4 b/libstdc++-v3/acinclude.m4 index 2a317e6..c9be65e 100644 --- a/libstdc++-v3/acinclude.m4 +++ b/libstdc++-v3/acinclude.m4 @@ -1577,6 +1577,23 @@ if test $enable_symvers != no; then CFLAGS=' -lgcc_s' AC_TRY_LINK(, [return 0;], glibcxx_shared_libgcc=yes, glibcxx_shared_libgcc=no) CFLAGS="$ac_save_CFLAGS" + if test $glibcxx_shared_libgcc = no; then + cat > conftest.c <<EOF +int main (void) { return 0; } +EOF +changequote(,)dnl + glibcxx_libgcc_s_suffix=`${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS \ + -shared -shared-libgcc -o conftest.so \ + conftest.c -v 2>&1 >/dev/null \ + | sed -n 's/^.* -lgcc_s\([^ ]*\) .*$/\1/p'` +changequote([,])dnl + rm -f conftest.c conftest.so + if test x${glibcxx_libgcc_s_suffix+set} = xset; then + CFLAGS=" -lgcc_s$glibcxx_libgcc_s_suffix" + AC_TRY_LINK(, [return 0;], glibcxx_shared_libgcc=yes) + CFLAGS="$ac_save_CFLAGS" + fi + fi AC_MSG_RESULT($glibcxx_shared_libgcc) fi diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure index 12ba7e6..fe0bb85 100755 --- a/libstdc++-v3/configure +++ b/libstdc++-v3/configure @@ -93676,6 +93676,70 @@ fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext CFLAGS="$ac_save_CFLAGS" + if test $glibcxx_shared_libgcc = no; then + cat > conftest.c <<EOF +int main (void) { return 0; } +EOF + glibcxx_libgcc_s_suffix=`${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS \ + -shared -shared-libgcc -o conftest.so \ + conftest.c -v 2>&1 >/dev/null \ + | sed -n 's/^.* -lgcc_s\([^ ]*\) .*$/\1/p'` + rm -f conftest.c conftest.so + if test x${glibcxx_libgcc_s_suffix+set} = xset; then + CFLAGS=" -lgcc_s$glibcxx_libgcc_s_suffix" + if test x$gcc_no_link = xyes; then + { { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5 +echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;} + { (exit 1); exit 1; }; } +fi +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +int +main () +{ +return 0; + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -z "$ac_c_werror_flag" + || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + glibcxx_shared_libgcc=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +fi +rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS="$ac_save_CFLAGS" + fi + fi echo "$as_me:$LINENO: result: $glibcxx_shared_libgcc" >&5 echo "${ECHO_T}$glibcxx_shared_libgcc" >&6 fi |