$OpenBSD: patch-configure,v 1.1 2012/05/25 09:05:49 sthen Exp $
--- configure.orig	Fri May 11 21:48:57 2012
+++ configure	Wed May 23 01:38:47 2012
@@ -12741,13 +12741,13 @@ fi
 
 if test "$LLVM_ENABLE_THREADS" -eq 1 && test "$ENABLE_PTHREADS" -eq 1 ; then
 
-{ echo "$as_me:$LINENO: checking for pthread_mutex_init in -lpthread" >&5
-echo $ECHO_N "checking for pthread_mutex_init in -lpthread... $ECHO_C" >&6; }
+{ echo "$as_me:$LINENO: checking for pthread_mutex_init in -pthread" >&5
+echo $ECHO_N "checking for pthread_mutex_init in -pthread... $ECHO_C" >&6; }
 if test "${ac_cv_lib_pthread_pthread_mutex_init+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lpthread  $LIBS"
+LIBS="-pthread  $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -12823,7 +12823,7 @@ if test $ac_cv_lib_pthread_pthread_mutex_init = yes; t
 #define HAVE_LIBPTHREAD 1
 _ACEOF
 
-  LIBS="-lpthread $LIBS"
+  LIBS="-pthread $LIBS"
 
 fi
 
