diff --git a/libjava/ChangeLog b/libjava/ChangeLog index 20b07262023ed302fbe85ecbe307ed4cf6f1ab7b..b77c9a90a98b7b29aee10d9c401c809c6c3e6218 100644 --- a/libjava/ChangeLog +++ b/libjava/ChangeLog @@ -1,3 +1,8 @@ +2004-06-18 Andreas Tobler <a.tobler@schweiz.ch> + + * testsuite/libjava.jni/jni.exp (gcj_jni_test_one): Add lgcc_s for + darwin. + 2004-06-18 Ranjit Mathew <rmathew@hotmail.com> * prims.cc (_Jv_CreateJavaVM): Install SEGV and FPE handlers, diff --git a/libjava/testsuite/libjava.jni/jni.exp b/libjava/testsuite/libjava.jni/jni.exp index b1f6d4e34f46e8b01c32d9378f528dbb90e03149..838b83324de706512b17f35f318d23ee64aa3106 100644 --- a/libjava/testsuite/libjava.jni/jni.exp +++ b/libjava/testsuite/libjava.jni/jni.exp @@ -11,7 +11,7 @@ proc gcj_jni_compile_c_to_so {file {options {}}} { set options "" # apple uses a different extension for shared/dynamic libraries -# so we check against powerpc-apple-darwin and set them to +# so we check against powerpc-apple-darwin and set them to # dylib, else we assume it's .so if { [ regexp {powerpc-apple-darwin} $host_triplet] } { @@ -131,7 +131,15 @@ proc gcj_jni_test_one {file} { lappend cxxflaglist "-L$cxxldlibflags" } - lappend cxxflaglist "-lstdc++" + # Darwin does not yet have a libgcc_s.dylib library. + # So we add it here. If the libgcc_s is installed, the libstdc++ + # would pick it up. + if { [ regexp {powerpc-apple-darwin} $host_triplet] } { + lappend cxxflaglist "-lgcc_s -lstdc++" + } else { + lappend cxxflaglist "-lstdc++" + } + set cxxflags [join $cxxflaglist] }