]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
OpenBSD: libpthreads requires OpenBSD 5.2 or later
authorStuart Henderson <sthen@openbsd.org>
Sun, 7 Apr 2013 02:47:50 +0000 (20:47 -0600)
committerAmos Jeffries <squid3@treenet.co.nz>
Sun, 7 Apr 2013 02:47:50 +0000 (20:47 -0600)
This patch imported form teh OpenBSD ports packaging implements a TODO in
DiskThreads component regarding wider system support for libpthreads.

configure.ac

index 93c276879fc723e4c16dda7e564d670ceefb45e5..a72e1d70a677c0edb29e93af3f9a63df00e34cf7 100644 (file)
@@ -589,6 +589,16 @@ for module in $squid_disk_module_candidates none; do
               fi
             fi
             ;;
+          openbsd)
+            if test `echo "$squid_host_os_version" | tr -d .` -lt 52 ; then
+                AC_MSG_NOTICE(pthread library requires OpenBSD 5.2 or later)
+                squid_opt_use_diskthreads="no"
+            else
+              SQUID_CFLAGS="$SQUID_CFLAGS -D_REENTRANT"
+              SQUID_CXXFLAGS="$SQUID_CXXFLAGS -D_REENTRANT"
+              LDFLAGS="$LDFLAGS -lpthread"
+            fi
+            ;;
           solaris)
             if test "x$GCC" = "xyes" ; then
               SQUID_CFLAGS="$SQUID_CFLAGS -D_REENTRANT -pthreads"