ID: 44462
Comment by: adam-phpbugs at adam dot gs
Reported By: graham+php at nexopia dot com
Status: Open
Bug Type: Compile Failure
Operating System: OSX
PHP Version: 5.2CVS-2008-03-18
New Comment:
this issue is still existent in PHP5.2.6 latest release as well as the
latest 5.2 sources any idea if this bug will ever be fixed?
Previous Comments:
------------------------------------------------------------------------
[2008-04-25 17:56:46] cthompson at nexopia dot com
I just sent the following to the php-install mailing list for
feedback.
Modify php-5.2.5/Zend/zend_ini_scanner.c:
--- /Users/cthompson/php-5.2.5.clean/Zend/zend_ini_scanner.c
2007-11-08 09:36:37.000000000 -0600
+++ ./zend_ini_scanner.c 2008-04-25 10:16:27.000000000 -0600
@@ -478,7 +478,7 @@
#define yymore() yymore_used_but_not_detected
#define YY_MORE_ADJ 0
#define YY_RESTORE_YY_MORE_OFFSET
-char *yytext;
+//char *yytext;
#define INITIAL 0
/*
+----------------------------------------------------------------------+
Modify php-5.2.5/Zend/zend_language_scanner.c:
--- /Users/cthompson/php-5.2.5.clean/Zend/zend_language_scanner.c
2007-11-08 09:36:37.000000000 -0600
+++ ./zend_language_scanner.c 2008-04-25 10:17:15.000000000 -0600
@@ -3009,7 +3009,7 @@
#define yymore() (yy_more_flag = 1)
#define YY_MORE_ADJ yy_more_len
#define YY_RESTORE_YY_MORE_OFFSET
-char *yytext;
+//char *yytext;
#define INITIAL 0
/*
This REMOVES the definition of yytext. I think this is okay because
the various defines in those files actually end up using the yy_text in
zend_global.h, at least as far as I can see.
Certainly, this allows PHP to compile but I am not at all sure if this
is going to cause other problems. Could someone please give me some
feedback?
Additionally, I believe php-5.2.5/sapi/cli/config.m4 should be modified
to compile using libtool on OS X:
--- /Users/cthompson/php-5.2.5.clean/sapi/cli/config.m4 2007-07-11
17:20:36.000000000 -0600
+++ ./config.m4 2008-04-25 11:51:57.000000000 -0600
@@ -17,7 +17,7 @@
BUILD_CLI="echo '\#! .' > php.sym && echo >>php.sym && nm -BCpg
\`echo \$(PHP_GLOBAL_OBJS) \$(PHP_CLI_OBJS) | sed
's/\([A-Za-z0-9_]*\)\.lo/\1.o/g'\` | \$(AWK) '{ if (((\$\$2 == \"T\") ||
(\$\$2 == \"D\") || (\$\$2 == \"B\")) && (substr(\$\$3,1,1) != \".\")) {
print \$\$3 } }' | sort -u >> php.sym && \$(LIBTOOL) --mode=link \$(CC)
-export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS)
\$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) -Wl,-brtl -Wl,-bE:php.sym
\$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS) \$(PHP_CLI_OBJS) \$(EXTRA_LIBS)
\$(ZEND_EXTRA_LIBS) -o \$(SAPI_CLI_PATH)"
;;
*darwin*)
- BUILD_CLI="\$(CC) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS)
\$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS)
\$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_CLI_OBJS:.lo=.o) \$(PHP_FRAMEWORKS)
\$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CLI_PATH)"
+ BUILD_CLI="\$(LIBTOOL) --mode=link \$(CC) \$(CFLAGS_CLEAN)
\$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS)
\$(PHP_GLOBAL_OBJS) \$(PHP_CLI_OBJS) \$(PHP_FRAMEWORKS) \$(EXTRA_LIBS)
\$(ZEND_EXTRA_LIBS) -o \$(SAPI_CLI_PATH)"
;;
*netware*)
BUILD_CLI="\$(LIBTOOL) --mode=link \$(CC) -export-dynamic
\$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS)
\$(PHP_RPATHS) \$(PHP_CLI_OBJS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS)
-Lnetware -lphp5lib -o \$(SAPI_CLI_PATH)"
Of course, the shipping version of PHP 5.2.5 would then also need the
php-5.2.5/configure file changing, though presumably this is
autogenerated from the fragments:
--- /Users/cthompson/php-5.2.5.clean/configure 2007-11-08
09:36:28.000000000 -0600
+++ ./configure 2008-04-25 11:27:46.000000000 -0600
@@ -9180,7 +9180,7 @@
BUILD_CLI="echo '\#! .' > php.sym && echo >>php.sym && nm -BCpg
\`echo \$(PHP_GLOBAL_OBJS) \$(PHP_CLI_OBJS) | sed
's/\([A-Za-z0-9_]*\)\.lo/\1.o/g'\` | \$(AWK) '{ if (((\$\$2 == \"T\") ||
(\$\$2 == \"D\") || (\$\$2 == \"B\")) && (substr(\$\$3,1,1) != \".\")) {
print \$\$3 } }' | sort -u >> php.sym && \$(LIBTOOL) --mode=link \$(CC)
-export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS)
\$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) -Wl,-brtl -Wl,-bE:php.sym
\$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS) \$(PHP_CLI_OBJS) \$(EXTRA_LIBS)
\$(ZEND_EXTRA_LIBS) -o \$(SAPI_CLI_PATH)"
;;
*darwin*)
- BUILD_CLI="\$(CC) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS)
\$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS)
\$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_CLI_OBJS:.lo=.o) \$(PHP_FRAMEWORKS)
\$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CLI_PATH)"
+ BUILD_CLI="\$(LIBTOOL) --mode=link \$(CC) \$(CFLAGS_CLEAN)
\$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS)
\$(PHP_GLOBAL_OBJS) \$(PHP_CLI_OBJS) \$(PHP_FRAMEWORKS) \$(EXTRA_LIBS)
\$(ZEND_EXTRA_LIBS) -o \$(SAPI_CLI_PATH)"
;;
*netware*)
BUILD_CLI="\$(LIBTOOL) --mode=link \$(CC) -export-dynamic
\$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS)
\$(PHP_RPATHS) \$(PHP_CLI_OBJS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS)
-Lnetware -lphp5lib -o \$(SAPI_CLI_PATH)"
Again, I really welcome feedback on this.
------------------------------------------------------------------------
[2008-04-25 15:00:36] cthompson at nexopia dot com
Problem still exists with latest snapshot on OS X. Any pointers on
where I can look to resolve this problem would be appreciated.
------------------------------------------------------------------------
[2008-03-19 00:19:06] graham+php at nexopia dot com
Yes, we have been using the embed sapi with great success on linux for
a while now. As far as I know, the bug is isolated to OSX.
------------------------------------------------------------------------
[2008-03-19 00:11:51] [EMAIL PROTECTED]
Compile with success on Linux.
------------------------------------------------------------------------
[2008-03-18 22:06:55] graham+php at nexopia dot com
Tried that out, still fails in the same way.
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/44462
--
Edit this bug report at http://bugs.php.net/?id=44462&edit=1