cvs: /php4 php.h php_regex.h /php4/ext/standard browscap.c reg.c url.c /php4/sapi/apache mod_php4.c sapi_apache.c
| From: | Rasmus Lerdorf | Date: | Sat, 30 Oct 1999 14:22:11 +0000 |
| Subject: | cvs: /php4 php.h php_regex.h /php4/ext/standard browscap.c reg.c url.c /php4/sapi/apache mod_php4.c sapi_apache.c | ||
| Groups: | php.version4 | ||
| Request: | Send a blank email to php-version4+get-5796@lists.php.net to get a copy of this message | ||
rasmus Sat Oct 30 10:22:11 1999 EDT
Modified files:
/php4 php.h php_regex.h
/php4/ext/standard browscap.c reg.c url.c
/php4/sapi/apache mod_php4.c sapi_apache.c
Log:
Clean up regex header file mess. php.h now explicitly includes php_regex.h
and php_regex.h figures out which regex header files to include and
defines symbols that prevents other stuff from including the wrong versions
of regex header files.
Index: php4/php.h
diff -u php4/php.h:1.40 php4/php.h:1.41
--- php4/php.h:1.40 Wed Oct 27 14:30:40 1999
+++ php4/php.h Sat Oct 30 10:22:08 1999
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: php.h,v 1.40 1999/10/27 18:30:40 thies Exp $ */
+/* $Id: php.h,v 1.41 1999/10/30 14:22:08 rasmus Exp $ */
#ifndef _PHP_H
#define _PHP_H
@@ -73,6 +73,7 @@
#define THREAD_LS
#endif
+#include "php_regex.h"
/* PHP's DEBUG value must match Zend's ZEND_DEBUG value */
#undef DEBUG
Index: php4/php_regex.h
diff -u php4/php_regex.h:1.3 php4/php_regex.h:1.4
--- php4/php_regex.h:1.3 Fri Oct 29 13:33:18 1999
+++ php4/php_regex.h Sat Oct 30 10:22:09 1999
@@ -3,11 +3,21 @@
#if REGEX
#include "regex/regex.h"
+#ifndef REGEX_H
#define _REGEX_H 1 /* this should stop Apache from loading the system version of regex.h */
+#endif
+#ifndef REGEX_H_
#define _REGEX_H_ 1
+#endif
+#ifndef RX_H
#define _RX_H 1 /* Try defining these for Linux to */
+#endif
+#ifndef REGEXP_LIBRARY_H
#define __REGEXP_LIBRARY_H__ 1 /* avoid Apache including regex.h */
+#endif
+#ifndef H_REGEX
#define _H_REGEX 1 /* This one is for AIX */
+#endif
#else
#include <regex.h>
#endif
Index: php4/ext/standard/browscap.c
diff -u php4/ext/standard/browscap.c:1.13 php4/ext/standard/browscap.c:1.14
--- php4/ext/standard/browscap.c:1.13 Fri Aug 27 15:17:19 1999
+++ php4/ext/standard/browscap.c Sat Oct 30 10:22:09 1999
@@ -19,7 +19,6 @@
#include "php.h"
#include "php3_browscap.h"
#include "php_ini.h"
-#include "php_regex.h"
#include "zend_globals.h"
Index: php4/ext/standard/reg.c
diff -u php4/ext/standard/reg.c:1.21 php4/ext/standard/reg.c:1.22
--- php4/ext/standard/reg.c:1.21 Mon Oct 4 09:04:32 1999
+++ php4/ext/standard/reg.c Sat Oct 30 10:22:09 1999
@@ -17,12 +17,11 @@
| Jaakko Hyvätti <jaakko@hyvatti.iki.fi> |
+----------------------------------------------------------------------+
*/
-/* $Id: reg.c,v 1.21 1999/10/04 13:04:32 thies Exp $ */
+/* $Id: reg.c,v 1.22 1999/10/30 14:22:09 rasmus Exp $ */
#include <stdio.h>
#include "php.h"
#include "php3_string.h"
-#include "php_regex.h"
#include "reg.h"
unsigned char third_argument_force_ref[] = { 3, BYREF_NONE, BYREF_NONE, BYREF_FORCE };
Index: php4/ext/standard/url.c
diff -u php4/ext/standard/url.c:1.12 php4/ext/standard/url.c:1.13
--- php4/ext/standard/url.c:1.12 Tue Oct 19 07:02:05 1999
+++ php4/ext/standard/url.c Sat Oct 30 10:22:09 1999
@@ -15,7 +15,7 @@
| Author: Jim Winstead (jimw@php.net) |
+----------------------------------------------------------------------+
*/
-/* $Id: url.c,v 1.12 1999/10/19 11:02:05 thies Exp $ */
+/* $Id: url.c,v 1.13 1999/10/30 14:22:09 rasmus Exp $ */
#include <stdlib.h>
#include <string.h>
@@ -23,7 +23,6 @@
#include <sys/types.h>
#include "php.h"
-#include "php_regex.h"
#include "url.h"
#ifdef _OSD_POSIX
Index: php4/sapi/apache/mod_php4.c
diff -u php4/sapi/apache/mod_php4.c:1.3 php4/sapi/apache/mod_php4.c:1.4
--- php4/sapi/apache/mod_php4.c:1.3 Mon Oct 4 11:18:25 1999
+++ php4/sapi/apache/mod_php4.c Sat Oct 30 10:22:10 1999
@@ -17,8 +17,11 @@
| PHP 4.0 patches by Zeev Suraski <zeev@zend.com> |
+----------------------------------------------------------------------+
*/
-/* $Id: mod_php4.c,v 1.3 1999/10/04 15:18:25 sas Exp $ */
+/* $Id: mod_php4.c,v 1.4 1999/10/30 14:22:10 rasmus Exp $ */
+#include "zend.h"
+#include "php.h"
+
#include "httpd.h"
#include "http_config.h"
#if MODULE_MAGIC_NUMBER > 19980712
@@ -34,8 +37,6 @@
#include "http_request.h"
#include "http_log.h"
-#include "zend.h"
-#include "php.h"
#include "php_ini.h"
#include "php_globals.h"
#include "SAPI.h"
Index: php4/sapi/apache/sapi_apache.c
diff -u php4/sapi/apache/sapi_apache.c:1.1 php4/sapi/apache/sapi_apache.c:1.2
--- php4/sapi/apache/sapi_apache.c:1.1 Mon Oct 4 11:18:25 1999
+++ php4/sapi/apache/sapi_apache.c Sat Oct 30 10:22:10 1999
@@ -19,8 +19,10 @@
| Stig Bakken <ssb@fast.no> |
+----------------------------------------------------------------------+
*/
-/* $Id: sapi_apache.c,v 1.1 1999/10/04 15:18:25 sas Exp $ */
+/* $Id: sapi_apache.c,v 1.2 1999/10/30 14:22:10 rasmus Exp $ */
+#include "php.h"
+
#include "httpd.h"
#include "http_config.h"
#if MODULE_MAGIC_NUMBER > 19980712
@@ -37,7 +39,6 @@
#include "http_log.h"
#include "zend.h"
-#include "php.h"
#include "php_ini.h"
#include "php_globals.h"
#include "SAPI.h"