aboutsummaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorAlexandre Oliva <aoliva@redhat.com>2002-03-01 00:52:59 +0000
committerAlexandre Oliva <aoliva@redhat.com>2002-03-01 00:52:59 +0000
commit2e8357fc19b020bc2e9a6a35507cd212b541b450 (patch)
tree8a4794e9a665aeded9d78fbe4588aed37b64824c /configure.in
parent7bb06ff250fa5188ba2b5014e0a17a975d9d135e (diff)
downloadgdb-2e8357fc19b020bc2e9a6a35507cd212b541b450.zip
gdb-2e8357fc19b020bc2e9a6a35507cd212b541b450.tar.gz
gdb-2e8357fc19b020bc2e9a6a35507cd212b541b450.tar.bz2
* configure.in (libstdcxx_flags): Don't add libstdc++-v3 flags for
libjava. (CXX_FOR_TARGET): Add -shared-libgcc for libstdc++-v3 and libjava.
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in17
1 files changed, 7 insertions, 10 deletions
diff --git a/configure.in b/configure.in
index c533c44..baf9d73 100644
--- a/configure.in
+++ b/configure.in
@@ -47,15 +47,9 @@ if [ "${enable_gdbgui}" = "yes" ] ; then
host_libs="${host_libs} libgui"
fi
-# Set up configure/Makefile variables if libstdc++-v3 is to be built.
-if [ "${enable_libstdcxx_v3}" = "yes" ] && test -d $srcdir/libstdc++-v3; then
- libstdcxx_version="target-libstdc++-v3"
- # Don't use libstdc++-v3's flags to configure/build itself.
- libstdcxx_flags='`case $$dir in libstdc++-v3) ;; *) cat $$r/$(TARGET_SUBDIR)/libstdc++-v3/src/libstdc++.INC 2>/dev/null || : ;; esac` -L$$r/$(TARGET_SUBDIR)/libstd++-v3/src -L$$r/$(TARGET_SUBDIR)/libstd++-v3/src/.libs'
-else
- libstdcxx_version="target-libio target-libstdc++"
- libstdcxx_flags='-isystem $$s/libstdc++ -isystem $$s/libstdc++/std -isystem $$s/libstdc++/stl -isystem $$s/libio/ -isystem $$s/libio/stdio -L$$r/$(TARGET_SUBDIR)/libstdc++'
-fi
+libstdcxx_version="target-libstdc++-v3"
+# Don't use libstdc++-v3's flags to configure/build itself.
+libstdcxx_flags='`case $$dir in libstdc++-v3 | libjava) ;; *) test ! -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/testsuite_flags || $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/testsuite_flags --build-includes;; esac` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs'
# these tools are built for the host environment
# Note, the powerpc-eabi build depends on sim occurring before gdb in order to
@@ -1443,7 +1437,10 @@ esac
if test "x${CXX_FOR_TARGET+set}" = xset; then
:
elif test -d ${topsrcdir}/gcc; then
- CXX_FOR_TARGET='$$r/gcc/`case $$dir in libstdc++-v3) echo xgcc ;; *) echo g++ ;; esac` -B$$r/gcc/ -nostdinc++ '$libstdcxx_flags
+ # We add -shared-libgcc to CXX_FOR_TARGET whenever we use xgcc instead
+ # of g++ for linking C++ or Java, because g++ has -shared-libgcc by
+ # default whereas gcc does not.
+ CXX_FOR_TARGET='$$r/gcc/`case $$dir in libstdc++-v3 | libjava) echo xgcc -shared-libgcc ;; *) echo g++ ;; esac` -B$$r/gcc/ -nostdinc++ '$libstdcxx_flags
elif test "$host" = "$target"; then
CXX_FOR_TARGET='$(CXX)'
else