#24016 [Bgs->Csd]: Cannot compile 4.3.2 with Apache 2.0.45/2.0.46 due to redeclaration of regex
| From: | sniper@php.net | Date: | Thu, 05 Jun 2003 04:15:26 +0000 |
| Subject: | #24016 [Bgs->Csd]: Cannot compile 4.3.2 with Apache 2.0.45/2.0.46 due to redeclaration of regex | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-41214@lists.php.net to get a copy of this message | ||
ID: 24016
Updated by: sniper@php.net
Reported By: chris at inglenook dot co dot uk
-Status: Bogus
+Status: Closed
Bug Type: *Compile Issues
Operating System: Redhat Linux 9
PHP Version: 4.3.2
New Comment:
Fixed in CVS.
Previous Comments:
------------------------------------------------------------------------
[2003-06-04 10:29:52] chris at inglenook dot co dot uk
fair enough
i figured that as it was already switching to the php regex for apache
and apache2filter out of the box, then it seemed to fit in with the way
things were done to do it for apache2handler aswell.
if my machine wasn't so slow to compile then i'd look to see what
changed from 2.0.44 - as i've tried both 2.0.45 and 2.0.46 as i said,
both have the problem.
4.3.1 didn't have the problem as it was covered by the apache2filter
test.
------------------------------------------------------------------------
[2003-06-04 10:20:20] iliaa@php.net
Perphaps a further explanation for the bogusing is needed ;).
While your patch may work for you, it does present several issues.
First of all apache 1 sapi works fine with system regex and so does
Apache 2 2.0.44 (at least in my tests). So, the patch itself is not
entirely valid. The problem you describe may infact be a temporary
issue that Apache 2 developers may resolve in later releases. Therefor,
arbitrarily disallowing system regex for users of apache sapis, is not
a good idea, at least IMO.
------------------------------------------------------------------------
[2003-06-04 09:18:58] iliaa@php.net
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to
report
a bug at http://bugs.php.net/how-to-report.php
Remove --with-regex=system from your configure line and recompile.
------------------------------------------------------------------------
[2003-06-04 09:14:26] chris at inglenook dot co dot uk
Compiling with the following configure line (in an rpm compile so
that's what the variables are):
%configure \
--prefix=%{_prefix} \
--with-config-file-path=%{_sysconfdir}/php \
--enable-force-cgi-redirect \
--enable-pic \
--disable-rpath \
--enable-inline-optimization \
--with-bz2 \
--with-db4 \
--with-curl \
--with-dom=%{_prefix} \
--with-exec-dir=%{_bindir} \
--with-freetype-dir=%{_prefix} \
--with-png-dir=%{_prefix} \
--with-gd \
--enable-gd-native-ttf \
--with-ttf \
--with-gdbm \
--with-gettext=shared \
--with-ncurses \
--with-gmp \
--with-iconv \
--with-jpeg-dir=%{_prefix} \
--with-openssl \
--with-png \
--with-pspell \
--with-regex=system \
--with-xml \
--with-expat-dir=%{_prefix} \
--with-zlib \
--with-layout=GNU \
--enable-bcmath \
--enable-debugger \
--enable-exif \
--with-pear=/usr/share/pear \
--enable-magic-quotes \
--enable-safe-mode \
--enable-sockets \
--enable-discard-path \
--enable-track-vars \
--enable-trans-sid \
--enable-yp \
--enable-wddx \
--without-oci8 \
--with-imap=shared \
--with-imap-ssl \
--with-kerberos=/usr/kerberos \
--with-ldap=shared \
--enable-sysvsem=shared \
--enable-sysvshm=shared \
--enable-ftp=shared \
--with-mysql=%{_prefix} \
--with-mcrypt \
%if %{oracle}
--with-oci8=shared \
%endif
--enable-memory-limit \
--enable-bcmath \
--enable-shmop \
--enable-versioning \
--enable-calendar \
--enable-dbx \
--enable-dio \
--enable-mbstring \
$*
This line works fine with php 4.3.1 and Apache 2.0.45 and 2.0.46.
PHP 4.3.2 introduces the apache2handler - this is where the problem
comes in.
The compile bombs out due to redeclaration or regex constants.
I think that this could be fixed by removing --with-regex=system
However, for PHP 4.3.1 and apache2filter the following line prevents
this problem:
if test "$PHP_SAPI" = "apache" || test "$PHP_SAPI" =
"apache2filter";
then
This goes on to force the use of php regex. This is in the configure
script, and comes from ext/standard/config.m4
I'm submitting this as although there may be workarounds, if the
problem can be fixed so a compile script from 4.3.1 can also work with
4.3.2 then it might stop others having the same trouble.
Patching this line to include apache2filter solves the compilation
problem:
if test "$PHP_SAPI" = "apache" || test "$PHP_SAPI" =
"apache2filter" ||
test "$PHP_SAPI" = "apache2handler"; then
The patch i use before compilation:
--- php-4.3.2/ext/standard/config.m4 2003-06-03 08:28:23.000000000
+0100
+++ php-4.3.2/ext/standard/config.m4 2003-06-03
08:28:10.000000000 +0100
@@ -205,7 +205,7 @@
[
case $withval in
system)
- if test "$PHP_SAPI" = "apache" || test "$PHP_SAPI" =
"apache2filter"; then
+ if test "$PHP_SAPI" = "apache" || test "$PHP_SAPI" =
"apache2filter" || test "$PHP_SAPI" = "apache2handler"; then
REGEX_TYPE=php
else
REGEX_TYPE=system
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=24016&edit=1