summaryrefslogtreecommitdiffstats
path: root/main/varnish/varnish-3.0.3-pthread-uclibc.patch
diff options
context:
space:
mode:
authorBartłomiej Piotrowski <b@bpiotrowski.pl>2012-12-17 19:06:47 +0100
committerBartłomiej Piotrowski <b@bpiotrowski.pl>2012-12-17 19:55:29 +0100
commit9ebf4c59cc8e931bbb13b2504d96c648f95c703f (patch)
tree840a9569e13fff2825366f1092c7730a37f4be77 /main/varnish/varnish-3.0.3-pthread-uclibc.patch
parent814e7531ff9a241a405d87e61162f45a42d8e031 (diff)
downloadaports-9ebf4c59cc8e931bbb13b2504d96c648f95c703f.tar.bz2
aports-9ebf4c59cc8e931bbb13b2504d96c648f95c703f.tar.xz
main/varnish: upgrade to 3.0.3
Diffstat (limited to 'main/varnish/varnish-3.0.3-pthread-uclibc.patch')
-rw-r--r--main/varnish/varnish-3.0.3-pthread-uclibc.patch35
1 files changed, 35 insertions, 0 deletions
diff --git a/main/varnish/varnish-3.0.3-pthread-uclibc.patch b/main/varnish/varnish-3.0.3-pthread-uclibc.patch
new file mode 100644
index 000000000..93f3da3f8
--- /dev/null
+++ b/main/varnish/varnish-3.0.3-pthread-uclibc.patch
@@ -0,0 +1,35 @@
+Refine header check in bin/varnishd/mgt/mgt.h, mgt_main.c for uClibc
+
+Because of the difference in how uClibc and glibc stack their header
+files, stdio.h indirectly brings in PTHREAD_CANCELED from pthread.h
+on a uClibc system, whereas it does not on a glibc system. This happens
+in mgt.h and mgt_main.c. This patch refines the check in those files
+to take this fact into consideration.
+
+X-Gentoo-Bug-URL: https://bugs.gentoo.org/444294
+---
+
+diff --git a/bin/varnishd/mgt.h b/bin/varnishd/mgt.h
+index 905fbcc..5d3ab09 100644
+--- a/bin/varnishd/mgt.h
++++ b/bin/varnishd/mgt.h
+@@ -126,6 +126,6 @@ extern unsigned mgt_vcc_unsafe_path;
+ syslog(pri, fmt, __VA_ARGS__); \
+ } while (0)
+
+-#if defined(PTHREAD_CANCELED) || defined(PTHREAD_MUTEX_DEFAULT)
++#if (defined(PTHREAD_CANCELED) && !defined(__UCLIBC__)) || defined(PTHREAD_MUTEX_DEFAULT)
+ #error "Keep pthreads out of in manager process"
+ #endif
+diff --git a/bin/varnishd/varnishd.c b/bin/varnishd/varnishd.c
+index 1b7f1e3..dce42d9 100644
+--- a/bin/varnishd/varnishd.c
++++ b/bin/varnishd/varnishd.c
+@@ -656,6 +656,6 @@ main(int argc, char * const *argv)
+ exit(exit_status);
+ }
+
+-#if defined(PTHREAD_CANCELED) || defined(PTHREAD_MUTEX_DEFAULT)
++#if (defined(PTHREAD_CANCELED) && !defined(__UCLIBC__)) || defined(PTHREAD_MUTEX_DEFAULT)
+ #error "Keep pthreads out of in manager process"
+ #endif