php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Return to Bug #62267
Patch php-5.4-apache-2.4.patch revision 2012-08-05 18:11 UTC by iomranic at gmail dot com
Patch php-5.4-apache-2.4 revision 2012-08-05 17:53 UTC by me at omranic dot com
Patch php5.3-apache24.diff revision 2012-06-08 18:09 UTC by neweracracker at gmail dot com

Patch php5.3-apache24.diff for Apache2 related Bug #62267

Patch version 2012-06-08 18:09 UTC

Return to Bug #62267 | Download this patch
This patch is obsolete

Obsoleted by patches:

Patch Revisions:

Developer: neweracracker@gmail.com

diff -uNr php5.3-201206072130/sapi/apache2handler/apache_config.c php5.3-new/sapi/apache2handler/apache_config.c
--- php5.3-201206072130/sapi/apache2handler/apache_config.c	Wed May 16 17:59:06 2012
+++ php5.3-new/sapi/apache2handler/apache_config.c	Fri Jun  8 09:58:15 2012
@@ -22,6 +22,7 @@
 
 #include "php.h"
 #include "php_ini.h"
+#include "php_network.h"
 #include "php_apache.h"
 
 #include "apr_strings.h"
diff -uNr php5.3-201206072130/sapi/apache2handler/config.w32 php5.3-new/sapi/apache2handler/config.w32
--- php5.3-201206072130/sapi/apache2handler/config.w32	Wed May 16 17:59:06 2012
+++ php5.3-new/sapi/apache2handler/config.w32	Fri Jun  8 10:01:25 2012
@@ -2,10 +2,9 @@
 // $Id$
 
 ARG_ENABLE('apache2handler', 'Build Apache 2.x handler', 'no');
-
 if (PHP_APACHE2HANDLER != "no") {
 	if (PHP_ZTS == "no") {
-		WARNING("Apache2 module requires an --enable-zts build of PHP on windows");
+		WARNING("Apache 2.0 module requires an --enable-zts build of PHP on windows");
 	} else if (CHECK_HEADER_ADD_INCLUDE("httpd.h", "CFLAGS_APACHE2HANDLER", PHP_PHP_BUILD + "\\include\\apache2") &&
 			CHECK_LIB("libhttpd.lib", "apache2handler", PHP_PHP_BUILD + "\\lib\\apache2") &&
 			CHECK_LIB("libapr.lib", "apache2handler", PHP_PHP_BUILD + "\\lib\\apache2") &&
@@ -20,10 +19,9 @@
 }
 
 ARG_ENABLE('apache2-2handler', 'Build Apache 2.2.x handler', 'no');
-
 if (PHP_APACHE2_2HANDLER != "no") {
 	if (PHP_ZTS == "no") {
-		WARNING("Apache2 module requires an --enable-zts build of PHP on windows");
+		WARNING("Apache 2.2 module requires an --enable-zts build of PHP on windows");
 	} else if (CHECK_HEADER_ADD_INCLUDE("httpd.h", "CFLAGS_APACHE2_2HANDLER", PHP_PHP_BUILD + "\\include\\apache2_2") &&
 			CHECK_LIB("libhttpd.lib", "apache2_2handler", PHP_PHP_BUILD + "\\lib\\apache2_2") &&
 			CHECK_LIB("libapr-1.lib", "apache2_2handler", PHP_PHP_BUILD + "\\lib\\apache2_2") &&
@@ -37,3 +35,21 @@
 		WARNING("Could not find apache2.2 libraries/headers");
 	}
 }
+
+ARG_ENABLE('apache2-4handler', 'Build Apache 2.4.x handler', 'no');
+if (PHP_APACHE2_4HANDLER != "no") {
+	if (PHP_ZTS == "no") {
+		WARNING("Apache 2.4 module requires an --enable-zts build of PHP on windows");
+	} else if (CHECK_HEADER_ADD_INCLUDE("httpd.h", "CFLAGS_APACHE2_4HANDLER", PHP_PHP_BUILD + "\\include\\apache2_4") &&
+			CHECK_LIB("libhttpd.lib", "apache2_4handler", PHP_PHP_BUILD + "\\lib\\apache2_4") &&
+			CHECK_LIB("libapr-1.lib", "apache2_4handler", PHP_PHP_BUILD + "\\lib\\apache2_4") &&
+			CHECK_LIB("libaprutil-1.lib", "apache2_4handler", PHP_PHP_BUILD + "\\lib\\apache2_4")
+			) {
+		SAPI('apache2_4handler', 'mod_php5.c sapi_apache2.c apache_config.c php_functions.c',
+				'php' + PHP_VERSION + 'apache2_4.dll',
+				'/D PHP_APACHE2_EXPORTS /I win32',
+				'sapi\\apache2handler');
+	} else {
+		WARNING("Could not find apache2.4 libraries/headers");
+	}
+}
\ No newline at end of file
diff -uNr php5.3-201206072130/sapi/apache2handler/mod_php5.c php5.3-new/sapi/apache2handler/mod_php5.c
--- php5.3-201206072130/sapi/apache2handler/mod_php5.c	Wed May 16 17:59:06 2012
+++ php5.3-new/sapi/apache2handler/mod_php5.c	Fri Jun  8 09:58:22 2012
@@ -23,6 +23,7 @@
 #define ZEND_INCLUDE_FULL_WINDOWS_HEADERS
 
 #include "php.h"
+#include "php_network.h"
 #include "php_apache.h"
 
 AP_MODULE_DECLARE_DATA module php5_module = {
diff -uNr php5.3-201206072130/sapi/apache2handler/php_functions.c php5.3-new/sapi/apache2handler/php_functions.c
--- php5.3-201206072130/sapi/apache2handler/php_functions.c	Wed May 16 17:59:06 2012
+++ php5.3-new/sapi/apache2handler/php_functions.c	Fri Jun  8 09:58:30 2012
@@ -25,6 +25,7 @@
 #include "ext/standard/info.h"
 #include "ext/standard/head.h"
 #include "php_ini.h"
+#include "php_network.h"
 #include "SAPI.h"
 
 #define CORE_PRIVATE
diff -uNr php5.3-201206072130/sapi/apache2handler/sapi_apache2.c php5.3-new/sapi/apache2handler/sapi_apache2.c
--- php5.3-201206072130/sapi/apache2handler/sapi_apache2.c	Wed May 16 17:59:06 2012
+++ php5.3-new/sapi/apache2handler/sapi_apache2.c	Fri Jun  8 09:58:38 2012
@@ -25,6 +25,7 @@
 #include "php.h"
 #include "php_main.h"
 #include "php_ini.h"
+#include "php_network.h"
 #include "php_variables.h"
 #include "SAPI.h"
 
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Nov 23 21:01:28 2024 UTC