From f1d4ab26bcbb5ae3f28b4eb927d1d53f8e25a84f Mon Sep 17 00:00:00 2001
From: Gerald Pfeifer <gerald@gcc.gnu.org>
Date: Sun, 16 Jan 2011 19:38:04 +0000
Subject: [PATCH] * configure.tgt (*-*-freebsd*): Add -lpthread to XLDFLAGS.

From-SVN: r168858
---
 libgomp/ChangeLog     | 4 ++++
 libgomp/configure.tgt | 5 +++++
 2 files changed, 9 insertions(+)

diff --git a/libgomp/ChangeLog b/libgomp/ChangeLog
index 7f35ad61db9a..2e9be60c1ab0 100644
--- a/libgomp/ChangeLog
+++ b/libgomp/ChangeLog
@@ -1,3 +1,7 @@
+2011-01-16  Gerald Pfeifer
+
+	* configure.tgt (*-*-freebsd*): Add -lpthread to XLDFLAGS.
+
 2010-12-14  Jakub Jelinek  <jakub@redhat.com>
 
 	PR fortran/46874
diff --git a/libgomp/configure.tgt b/libgomp/configure.tgt
index 4a564452cefd..429c8e6bca29 100644
--- a/libgomp/configure.tgt
+++ b/libgomp/configure.tgt
@@ -124,6 +124,11 @@ case "${target}" in
 	config_path="bsd posix"
 	;;
 
+  *-*-freebsd*)
+	# Need to link with -lpthread so libgomp.so is self-contained.
+	XLDFLAGS="${XLDFLAGS} -lpthread"
+	;;
+
   mips-sgi-irix6*)
 	# Need to link with -lpthread so libgomp.so is self-contained.
 	XLDFLAGS="${XLDFLAGS} -lpthread"
-- 
GitLab