diff options
author | andreast <andreast@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-03-23 19:25:19 +0000 |
---|---|---|
committer | andreast <andreast@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-03-23 19:25:19 +0000 |
commit | e00b21424f1b27ce0822f915a07174ff3ba85680 (patch) | |
tree | dbb5e839cddaaac02bf54e9eb8aec18d32f52593 /libgomp/testsuite/libgomp.c++ | |
parent | 9671b27d426ebeecf6309006ee04a2c141b539c1 (diff) | |
download | ppe42-gcc-e00b21424f1b27ce0822f915a07174ff3ba85680.tar.gz ppe42-gcc-e00b21424f1b27ce0822f915a07174ff3ba85680.zip |
2007-03-23 Andreas Tobler <a.tobler@schweiz.org>
* testsuite/lib/libgomp.exp (libgomp_init): Add -shared-libgcc for
*-*-darwin*.
* testsuite/libgomp.c++/c++.exp: Look for shared libstdc++ library
and use it if found.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@123162 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libgomp/testsuite/libgomp.c++')
-rw-r--r-- | libgomp/testsuite/libgomp.c++/c++.exp | 26 |
1 files changed, 21 insertions, 5 deletions
diff --git a/libgomp/testsuite/libgomp.c++/c++.exp b/libgomp/testsuite/libgomp.c++/c++.exp index 0bc657e2125..213ce029ec7 100644 --- a/libgomp/testsuite/libgomp.c++/c++.exp +++ b/libgomp/testsuite/libgomp.c++/c++.exp @@ -1,14 +1,30 @@ -set lang_library_path "../libstdc++-v3/src/.libs" -set lang_test_file "${lang_library_path}/libstdc++.a" -set lang_link_flags "-lstdc++" - load_lib libgomp-dg.exp +global shlib_ext + +set shlib_ext [get_shlib_extension] +set lang_link_flags "-lstdc++" +set lang_test_file_found 0 +set lang_library_path "../libstdc++-v3/src/.libs" + # Initialize dg. dg-init -if [file exists "${blddir}/${lang_test_file}"] { +set blddir [lookfor_file [get_multilibs] libgomp] + +# Look for a static libstdc++ first. +if [file exists "${blddir}/${lang_library_path}/libstdc++.a"] { + set lang_test_file "${lang_library_path}/libstdc++.a" + set lang_test_file_found 1 +# We may have a shared only build, so look for a shared libstdc++. +} elseif [file exists "${blddir}/${lang_library_path}/libstdc++.${shlib_ext}"] { + set lang_test_file "${lang_library_path}/libstdc++.${shlib_ext}" + set lang_test_file_found 1 +} else { + puts "No libstdc++ library found, will not execute c++ tests" +} +if { $lang_test_file_found } { # Gather a list of all tests. set tests [lsort [glob -nocomplain $srcdir/$subdir/*.C]] |