aboutsummaryrefslogtreecommitdiffstats
path: root/www/nginx
diff options
context:
space:
mode:
authorosa <osa@FreeBSD.org>2011-08-11 00:22:58 +0800
committerosa <osa@FreeBSD.org>2011-08-11 00:22:58 +0800
commit97c051f5965e5eabefa40f8dd41114b265f9de75 (patch)
treee738aad2992fb73940eaf7d68900317a0da8a82e /www/nginx
parentf2586f0dddcfbeeb3197e83fcec3fcef13ab75a1 (diff)
downloadfreebsd-ports-gnome-97c051f5965e5eabefa40f8dd41114b265f9de75.tar.gz
freebsd-ports-gnome-97c051f5965e5eabefa40f8dd41114b265f9de75.tar.zst
freebsd-ports-gnome-97c051f5965e5eabefa40f8dd41114b265f9de75.zip
Update from 3.0.7 to 3.0.8:
1) www/rubygem-passenger; 2) passenger support for www/nginx and www/nginx-devel; Also add patch for fix NULL pointer crash that occurs when HTTP 1.0 Host header isn't given, obtained from passenger's upstream. Approved by: maintainer [1]
Diffstat (limited to 'www/nginx')
-rw-r--r--www/nginx/Makefile8
-rw-r--r--www/nginx/distinfo4
-rw-r--r--www/nginx/files/extra-patch-passenger::build::nginx.rb4
-rw-r--r--www/nginx/files/extra-patch-passenger::ext::nginx::ContentHandler.c54
4 files changed, 63 insertions, 7 deletions
diff --git a/www/nginx/Makefile b/www/nginx/Makefile
index d6727902a3db..0a72b7f223d6 100644
--- a/www/nginx/Makefile
+++ b/www/nginx/Makefile
@@ -464,11 +464,12 @@ CONFIGURE_ARGS+=--with-pcre
.endif
.if defined(WITH_PASSENGER_MODULE)
-PASSENGER_VERSION= 3.0.7
+PASSENGER_VERSION= 3.0.8
MASTER_SITES+= RF/passenger/:passenger
DISTFILES+= passenger-${PASSENGER_VERSION}.tar.gz:passenger
CONFIGURE_ARGS+=--add-module=${WRKDIR}/passenger-${PASSENGER_VERSION}/ext/nginx
-EXTRA_PATCHES+= ${PATCHDIR}/extra-patch-passenger::build::nginx.rb
+EXTRA_PATCHES+= ${PATCHDIR}/extra-patch-passenger::build::nginx.rb \
+ ${PATCHDIR}/extra-patch-passenger::ext::nginx::ContentHandler.c
.if !defined(WITH_DEBUG)
CONFIGURE_ENV+= OPTIMIZE="yes"
CFLAGS+= -DNDEBUG
@@ -629,7 +630,8 @@ post-patch:
${WRKDIR}/passenger-${PASSENGER_VERSION}/build/config.rb
@${REINPLACE_CMD} \
's!-I/usr/include/libev!!; \
- s!-lev!!' \
+ s!-lev!!; \
+ s!-Iext/libev!!' \
${WRKDIR}/passenger-${PASSENGER_VERSION}/build/common_library.rb
@${REINPLACE_CMD} 's!-lpthread!${PTHREAD_LIBS}!g' \
${WRKDIR}/passenger-${PASSENGER_VERSION}/lib/phusion_passenger/platform_info/compiler.rb
diff --git a/www/nginx/distinfo b/www/nginx/distinfo
index 02ca05564d2b..4e2ee7ea6702 100644
--- a/www/nginx/distinfo
+++ b/www/nginx/distinfo
@@ -58,8 +58,8 @@ SHA256 (chaoslawful-lua-nginx-module-v0.2.0-0-g8e7d37e.tar.gz) = abdd6409962a93a
SIZE (chaoslawful-lua-nginx-module-v0.2.0-0-g8e7d37e.tar.gz) = 94607
SHA256 (agentzh-memc-nginx-module-v0.12-0-g4f1952c.tar.gz) = e0f604e20312bbd30ac88b2d83faa54f4668e6f6227762d2fc14e1d37df0b1de
SIZE (agentzh-memc-nginx-module-v0.12-0-g4f1952c.tar.gz) = 36414
-SHA256 (passenger-3.0.7.tar.gz) = 021972c7f4fecd80042e7fc1d8f19ee3008a5491a3b1d34958b2b7ed42bddc85
-SIZE (passenger-3.0.7.tar.gz) = 2830376
+SHA256 (passenger-3.0.8.tar.gz) = ccef21dc97b54de17c1d44644b2bc67b7732a860ff67206a4c557727311a8349
+SIZE (passenger-3.0.8.tar.gz) = 2362561
SHA256 (ngx_postgres-0.8.tar.gz) = 321de5ddfe95da45550a2b1d29cfcd425ed7d7d63edb0e086406486675d04283
SIZE (ngx_postgres-0.8.tar.gz) = 40108
SHA256 (agentzh-redis2-nginx-module-v0.07-0-g6f7fc37.tar.gz) = 3fbc76fbf60e02e879184b28cb9e834a4bb8f10ecd073ebd3cc585c469650b1a
diff --git a/www/nginx/files/extra-patch-passenger::build::nginx.rb b/www/nginx/files/extra-patch-passenger::build::nginx.rb
index fc556de2dee6..f6b0bb80b97a 100644
--- a/www/nginx/files/extra-patch-passenger::build::nginx.rb
+++ b/www/nginx/files/extra-patch-passenger::build::nginx.rb
@@ -1,5 +1,5 @@
---- ../passenger-3.0.7/build/nginx.rb.orig 2010-12-07 13:57:32.000000000 +0300
-+++ ../passenger-3.0.7/build/nginx.rb 2010-12-07 13:58:13.000000000 +0300
+--- ../passenger-3.0.8/build/nginx.rb.orig 2010-12-07 13:57:32.000000000 +0300
++++ ../passenger-3.0.8/build/nginx.rb 2010-12-07 13:58:13.000000000 +0300
@@ -23,10 +23,7 @@
desc "Build Nginx helper agent"
diff --git a/www/nginx/files/extra-patch-passenger::ext::nginx::ContentHandler.c b/www/nginx/files/extra-patch-passenger::ext::nginx::ContentHandler.c
new file mode 100644
index 000000000000..b71bd650bbb9
--- /dev/null
+++ b/www/nginx/files/extra-patch-passenger::ext::nginx::ContentHandler.c
@@ -0,0 +1,54 @@
+--- ../passenger-3.0.8/ext/nginx/ContentHandler.c.orig 2011-08-10 10:35:24.000000000 +0400
++++ ../passenger-3.0.8/ext/nginx/ContentHandler.c 2011-08-10 10:36:35.000000000 +0400
+@@ -336,6 +336,7 @@
+ ngx_table_elt_t *header;
+ ngx_http_script_code_pt code;
+ ngx_http_script_engine_t e, le;
++ ngx_http_core_srv_conf_t *cscf;
+ passenger_loc_conf_t *slcf;
+ passenger_main_conf_t *main_conf;
+ passenger_context_t *context;
+@@ -344,6 +345,7 @@
+ ngx_http_ssl_srv_conf_t *ssl_conf;
+ #endif
+
++ cscf = ngx_http_get_module_srv_conf(r, ngx_http_core_module);
+ slcf = ngx_http_get_module_loc_conf(r, ngx_http_passenger_module);
+ main_conf = &passenger_main_conf;
+ context = ngx_http_get_module_ctx(r, ngx_http_passenger_module);
+@@ -415,11 +417,15 @@
+ }
+
+ /* SERVER_NAME; must be equal to HTTP_HOST without the port part */
+- tmp = memchr(r->headers_in.host->value.data, ':', r->headers_in.host->value.len);
+- if (tmp == NULL) {
+- server_name_len = r->headers_in.host->value.len;
++ if (r->headers_in.host != NULL) {
++ tmp = memchr(r->headers_in.host->value.data, ':', r->headers_in.host->value.len);
++ if (tmp == NULL) {
++ server_name_len = r->headers_in.host->value.len;
++ } else {
++ server_name_len = (int) ((const u_char *) tmp - r->headers_in.host->value.data);
++ }
+ } else {
+- server_name_len = (int) ((const u_char *) tmp - r->headers_in.host->value.data);
++ server_name_len = cscf->server_name.len;
+ }
+ len += sizeof("SERVER_NAME") + server_name_len + 1;
+
+@@ -650,8 +656,13 @@
+
+ /* SERVER_NAME */
+ b->last = ngx_copy(b->last, "SERVER_NAME", sizeof("SERVER_NAME"));
+- b->last = ngx_copy(b->last, r->headers_in.host->value.data,
+- server_name_len);
++ if (r->headers_in.host != NULL) {
++ b->last = ngx_copy(b->last, r->headers_in.host->value.data,
++ server_name_len);
++ } else {
++ b->last = ngx_copy(b->last, cscf->server_name.data,
++ server_name_len);
++ }
+ b->last = ngx_copy(b->last, "", 1);
+
+ /* Various other HTTP headers. */