From 3276df05a758f8081adb6a910abf8de627ebda46 Mon Sep 17 00:00:00 2001 From: jonhermansen Date: Wed, 5 Nov 2025 23:28:02 +0000 Subject: [PATCH] fix tsan tests on FreeBSD by linking to pthread (#944) --- testsuite/lib/libffi.exp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/testsuite/lib/libffi.exp b/testsuite/lib/libffi.exp index 81eff775..308db6f8 100644 --- a/testsuite/lib/libffi.exp +++ b/testsuite/lib/libffi.exp @@ -407,6 +407,10 @@ proc libffi_target_compile { source dest type options } { lappend options "libs= -lpthread" } + if { [string match "*-*-freebsd*" $target_triplet] } { + lappend options "libs= -lpthread" + } + lappend options "libs= -lffi" if { [string match "aarch64*-*-linux*" $target_triplet] } {