Commit 31362d785ed1db52516dfe02ebe8b163c53d29d0

Yuriy Kolerov 2016-07-28T18:48:23

ARC: Link tests with pthread library Signed-off-by: Yuriy Kolerov <yuriy.kolerov@synopsys.com>

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
diff --git a/testsuite/lib/libffi.exp b/testsuite/lib/libffi.exp
index afc421b..de91e3b 100644
--- a/testsuite/lib/libffi.exp
+++ b/testsuite/lib/libffi.exp
@@ -219,6 +219,10 @@ proc libffi_target_compile { source dest type options } {
 	lappend options "c++"
     }
 
+    if { [string match "arc*-*-linux*" $target_triplet] } {
+	lappend options "libs= -lpthread"
+    }
+
     verbose "options: $options"
     return [target_compile $source $dest $type $options]
 }