diff options
author | Pacho Ramos <pacho@gentoo.org> | 2014-06-09 11:59:51 +0000 |
---|---|---|
committer | Pacho Ramos <pacho@gentoo.org> | 2014-06-09 11:59:51 +0000 |
commit | 03134d23ff9d035f375bb781090f13f86f1ee59e (patch) | |
tree | aeddad5c1e78abefc9aa7fa33b505a4613b21fd8 /www-apache | |
parent | Stable for amd64 wrt bug #512108 (diff) | |
download | gentoo-2-03134d23ff9d035f375bb781090f13f86f1ee59e.tar.gz gentoo-2-03134d23ff9d035f375bb781090f13f86f1ee59e.tar.bz2 gentoo-2-03134d23ff9d035f375bb781090f13f86f1ee59e.zip |
Apply patch to be compatible with apache-2.4 (#506610 by Fabian Henze)
(Portage version: 2.2.10/cvs/Linux x86_64, signed Manifest commit with key A188FBD4)
Diffstat (limited to 'www-apache')
-rw-r--r-- | www-apache/mod_bw/ChangeLog | 10 | ||||
-rw-r--r-- | www-apache/mod_bw/files/mod_bw-0.9.2-apache24.patch | 49 | ||||
-rw-r--r-- | www-apache/mod_bw/mod_bw-0.9.2-r1.ebuild | 30 |
3 files changed, 87 insertions, 2 deletions
diff --git a/www-apache/mod_bw/ChangeLog b/www-apache/mod_bw/ChangeLog index 20c1344ff906..996b2f76fb02 100644 --- a/www-apache/mod_bw/ChangeLog +++ b/www-apache/mod_bw/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for www-apache/mod_bw -# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/www-apache/mod_bw/ChangeLog,v 1.13 2012/11/27 19:10:15 pacho Exp $ +# Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/www-apache/mod_bw/ChangeLog,v 1.14 2014/06/09 11:59:51 pacho Exp $ + +*mod_bw-0.9.2-r1 (09 Jun 2014) + + 09 Jun 2014; Pacho Ramos <pacho@gentoo.org> + +files/mod_bw-0.9.2-apache24.patch, +mod_bw-0.9.2-r1.ebuild: + Apply patch to be compatible with apache-2.4 (#506610 by Fabian Henze) 27 Nov 2012; Pacho Ramos <pacho@gentoo.org> -mod_bw-0.8.ebuild, -mod_bw-0.9.1.ebuild, metadata.xml: diff --git a/www-apache/mod_bw/files/mod_bw-0.9.2-apache24.patch b/www-apache/mod_bw/files/mod_bw-0.9.2-apache24.patch new file mode 100644 index 000000000000..27af0dbc1c6f --- /dev/null +++ b/www-apache/mod_bw/files/mod_bw-0.9.2-apache24.patch @@ -0,0 +1,49 @@ +--- a/mod_bw.c 2010-07-20 18:14:30.000000000 +0200 ++++ b/mod_bw.c 2014-03-31 14:36:27.064883758 +0200 +@@ -105,6 +105,10 @@ Changelog : + #define apr_atomic_set32 apr_atomic_set + #endif + ++#define APACHE_VERSION_AT_LEAST(major,minor) \ ++(((major) < AP_SERVER_MAJORVERSION_NUMBER) \ ++ || ((major) == AP_SERVER_MAJORVERSION_NUMBER && (minor) <= AP_SERVER_MINORVERSION_NUMBER)) ++ + /* Enum types of "from address" */ + enum from_type { + T_ALL, +@@ -564,7 +568,11 @@ static long get_bw_rate(request_rec * r, + return e[i].rate; + + case T_IP: ++#if APACHE_VERSION_AT_LEAST(2,4) ++ if (apr_ipsubnet_test(e[i].x.ip, r->useragent_addr)) { ++#else + if (apr_ipsubnet_test(e[i].x.ip, r->connection->remote_addr)) { ++#endif + return e[i].rate; + } + break; +@@ -655,7 +663,11 @@ static int get_maxconn(request_rec * r, + return e[i].max; + + case T_IP: ++#if APACHE_VERSION_AT_LEAST(2,4) ++ if (apr_ipsubnet_test(e[i].x.ip, r->useragent_addr)) { ++#else + if (apr_ipsubnet_test(e[i].x.ip, r->connection->remote_addr)) { ++#endif + return e[i].max; + } + break; +@@ -706,7 +718,11 @@ static int get_sid(request_rec * r, apr_ + return e[i].sid; + + case T_IP: ++#if APACHE_VERSION_AT_LEAST(2,4) ++ if (apr_ipsubnet_test(e[i].x.ip, r->useragent_addr)) { ++#else + if (apr_ipsubnet_test(e[i].x.ip, r->connection->remote_addr)) { ++#endif + return e[i].sid; + } + break; diff --git a/www-apache/mod_bw/mod_bw-0.9.2-r1.ebuild b/www-apache/mod_bw/mod_bw-0.9.2-r1.ebuild new file mode 100644 index 000000000000..562a4b309b37 --- /dev/null +++ b/www-apache/mod_bw/mod_bw-0.9.2-r1.ebuild @@ -0,0 +1,30 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/www-apache/mod_bw/mod_bw-0.9.2-r1.ebuild,v 1.1 2014/06/09 11:59:50 pacho Exp $ + +EAPI=5 +inherit apache-module eutils + +DESCRIPTION="Bandwidth Management Module for Apache2." +HOMEPAGE="http://www.ivn.cl/apache/" + +SRC_URI="http://ivn.cl/files/source/${P/9./9}.tgz" + +KEYWORDS="~amd64 ~ppc ~x86" +LICENSE="Apache-2.0" +SLOT="0" +IUSE="" + +DEPEND="sys-devel/libtool" +RDEPEND="" + +APACHE2_MOD_CONF="11_${PN}" +APACHE2_MOD_DEFINE="BW" + +need_apache2 + +S="${WORKDIR}" + +src_prepare() { + epatch "${FILESDIR}/${P}-apache24.patch" +} |