Use -lpthread on OpenBSD
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39
diff --git a/cmake/sdlchecks.cmake b/cmake/sdlchecks.cmake
index 8a19e5b..3686f01 100644
--- a/cmake/sdlchecks.cmake
+++ b/cmake/sdlchecks.cmake
@@ -905,7 +905,7 @@ macro(CheckPTHREAD)
set(PTHREAD_LDFLAGS "-lpthread")
elseif(OPENBSD)
set(PTHREAD_CFLAGS "-D_REENTRANT")
- set(PTHREAD_LDFLAGS "-pthread")
+ set(PTHREAD_LDFLAGS "-lpthread")
elseif(SOLARIS)
set(PTHREAD_CFLAGS "-D_REENTRANT")
set(PTHREAD_LDFLAGS "-pthread -lposix4")
diff --git a/configure b/configure
index 76d1d3e..072eedb 100755
--- a/configure
+++ b/configure
@@ -26778,7 +26778,7 @@ fi
;;
*-*-openbsd*)
pthread_cflags="-D_REENTRANT"
- pthread_lib="-pthread"
+ pthread_lib="-lpthread"
;;
*-*-solaris2.9)
# From Solaris 9+, posix4's preferred name is rt.
diff --git a/configure.ac b/configure.ac
index 5810b4f..6391bae 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3063,7 +3063,7 @@ dnl This is used on Linux for glibc binary compatibility (Doh!)
;;
*-*-openbsd*)
pthread_cflags="-D_REENTRANT"
- pthread_lib="-pthread"
+ pthread_lib="-lpthread"
;;
*-*-solaris2.9)
# From Solaris 9+, posix4's preferred name is rt.