]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
libstdc++.exp (v3-build_support): Look for __GTHREADS...
authorMark Mitchell <mark@codesourcery.com>
Thu, 5 May 2005 04:05:35 +0000 (04:05 +0000)
committerMark Mitchell <mmitchel@gcc.gnu.org>
Thu, 5 May 2005 04:05:35 +0000 (04:05 +0000)
* testsuite/lib/libstdc++.exp (v3-build_support): Look for
__GTHREADS, rather than _GLIBCXX_HAVE_GTHR_DEFAULT, to determine
whether or not thread support is available.

From-SVN: r99256

libstdc++-v3/ChangeLog
libstdc++-v3/testsuite/lib/libstdc++.exp

index 0eb21b15948fd006b162ab0c4330873edc3205ec..414e88390cf89693a1cf4f96e5ea0c98c874b7d7 100644 (file)
@@ -1,5 +1,9 @@
 2005-05-04  Mark Mitchell  <mark@codesourcery.com>
 
+       * testsuite/lib/libstdc++.exp (v3-build_support): Look for
+       __GTHREADS, rather than _GLIBCXX_HAVE_GTHR_DEFAULT, to determine
+       whether or not thread support is available.
+
        * docs/html/test.html: Explain how to run the testsuite on an
        installed directory. 
 
index 7f8008538eb119bb7bdf01cded0f06b85979e30f..60624df260349eaff69ab94536dd3f73a8f56be9 100644 (file)
@@ -314,17 +314,17 @@ proc v3-build_support {} {
     set config_src "config.cc"
     set f [open $config_src "w"]
     puts $f "#include <bits/c++config.h>"
+    puts $f "#include <bits/gthr.h>"
     close $f
     set preprocessed [v3_target_compile $config_src "" \
                       preprocess "additional_flags=-dN"]
-    foreach l $preprocessed {
-       if { [string first "_GLIBCXX_USE_WCHAR_T" $l] != -1 } {
-           verbose -log "wchar_t support detected"
-           set v3-wchar_t 1
-       } elseif { [string first "_GLIBCXX_HAVE_GTHR_DEFAULT" $l] != -1 } {
-           verbose -log "thread support detected"
-           set v3-threads 1
-       }
+    if { [string first "_GLIBCXX_USE_WCHAR_T" $preprocessed] != -1 } {
+       verbose -log "wchar_t support detected"
+       set v3-wchar_t 1
+    }
+    if { [string first "__GTHREADS" $preprocessed] != -1 } {
+       verbose -log "thread support detected"
+       set v3-threads 1
     }
 
     # Build the support objects.