$OpenBSD: patch-configure,v 1.1.1.1 2012/03/30 13:16:33 phessler Exp $
--- configure.orig	Mon Mar 26 19:45:55 2012
+++ configure	Mon Mar 26 19:46:28 2012
@@ -12165,13 +12165,13 @@ fi
 # required libraries
 # pthreads (not on win32)
 if test "${SYS}" != "mingw32" ; then
-    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthread" >&5
-$as_echo_n "checking for pthread_create in -lpthread... " >&6; }
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -pthread" >&5
+$as_echo_n "checking for pthread_create in -pthread... " >&6; }
 if ${ac_cv_lib_pthread_pthread_create+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lpthread  $LIBS"
+LIBS="-pthread  $LIBS"
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
@@ -12202,7 +12202,7 @@ fi
 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_create" >&5
 $as_echo "$ac_cv_lib_pthread_pthread_create" >&6; }
 if test "x$ac_cv_lib_pthread_pthread_create" = xyes; then :
-  LIBS="$LIBS -lpthread"
+  LIBS="$LIBS -pthread"
 fi
 
 fi
@@ -12559,8 +12559,6 @@ fi
 
 # use optimizations
 if [ $use_optimizations = "yes" ]; then
-  check_cc_options -O3 && \
-    SET_OPTIMIZATIONS="$SET_OPTIMIZATIONS -O3"
   check_cc_options -fomit-frame-pointer && \
     SET_OPTIMIZATIONS="$SET_OPTIMIZATIONS -fomit-frame-pointer"
 fi
