ID: 23774
Comment by: nitro1710 at hotmail dot com
Reported By: guillaume dot rix at sun dot com
Status: Bogus
Bug Type: Compile Failure
Operating System: Solaris 9
PHP Version: 4.3.2RC4
New Comment:

I have this same problem on FreeBSD 4.8-stable for upgrading to
4.3.3RC2... I get the same error.. Do I have to install the Gnu Sed
too? I upgraded my FreeBSD sed and it's still making error...


Previous Comments:
------------------------------------------------------------------------

[2003-05-23 10:05:23] [email]sniperphp.net[/email]

[url]http://mail.gnu.org/archive/html/libtool/2001-07/msg00101.html[/url]

(the sed in PATH in most of the solaris systems is the broken one which
can't handle lines over 1024 chars, iirc)


------------------------------------------------------------------------

[2003-05-23 09:59:09] guillaume dot rix at sun dot com

Hi,

Thanks for your quick answer on this.

Do you have any reference on this BUG of sed for me ?
It will be very appreciated.

Thanks in advance!

Guillaume,

------------------------------------------------------------------------

[2003-05-23 09:56:04] [email]sniperphp.net[/email]

Due to a bug in the installed sed on your system the build
fails. Install GNU sed and it should be okay.

Thank you for your interest in PHP.

..

------------------------------------------------------------------------

[2003-05-23 06:38:16] guillaume dot rix at sun dot com

PHP version tested ===>

4.3.2RC3 and 4.3.1

System ===>

SunOS -a 5.9 Generic sun4u sparc SUNW,Ultra-5_10

BUG Description ===>

bash-2.05# gunzip -c php-4.3.1.tar.gz | tar xvf -
bash-2.05# cd ../php-4.3.1
bash-2.05# CFLAGS='-DEAPI' ./configure
--with-apxs=/usr/local/apache/bin/apxs --with-mysql=/usr/local/mysql
--with-zlib=/usr/local
--with-gd

No problem during the configure.

bash-2.05# make

gcc -Imain/ -I/space/IDS/apache/php-4.3.2RC3/main/ -DPHP_ATOM_INC
-I/space/IDS/apache/php-4.3.2RC3/include
-I/space/IDS/apache/php-4.3.2RC3/main -I/space/IDS/apache/php-4.3.2RC3
-I/space/IDS/apache/php-4.3.2RC3/Zend
-I/usr/local/mysql/include
-I/space/IDS/apache/php-4.3.2RC3/ext/xml/expat
-D_POSIX_PTHREAD_SEMANTICS
-I/space/IDS/apache/php-4.3.2RC3/TSRM -c main/internal_functions.c -o
main/internal_functions.o && echo > main/internal_functions.lo
main/internal_functions.c:41: `phpext_xml_ptr' undeclared here (not in
a function)
main/internal_functions.c:41: initializer element is not constant
main/internal_functions.c:41: (near initialization for
`php_builtin_extensions[0]')
main/internal_functions.c:42: `phpext_tokenizer_ptr' undeclared here
(not in a function)
main/internal_functions.c:42: initializer element is not constant
main/internal_functions.c:42: (near initialization for
`php_builtin_extensions[1]')
main/internal_functions.c:43: `phpext_standard_ptr' undeclared here
(not in a function)
main/internal_functions.c:43: initializer element is not constant
main/internal_functions.c:43: (near initialization for
`php_builtin_extensions[2]')
main/internal_functions.c:44: `phpext_session_ptr' undeclared here (not
in a function)
main/internal_functions.c:44: initializer element is not constant
main/internal_functions.c:44: (near initialization for
`php_builtin_extensions[3]')
main/internal_functions.c:45: `phpext_posix_ptr' undeclared here (not
in a function)
main/internal_functions.c:45: initializer element is not constant
main/internal_functions.c:45: (near initialization for
`php_builtin_extensions[4]')
main/internal_functions.c:46: `phpext_pcre_ptr' undeclared here (not in
a function)
main/internal_functions.c:46: initializer element is not constant
main/internal_functions.c:46: (near initialization for
`php_builtin_extensions[5]')
main/internal_functions.c:47: `phpext_overload_ptr' undeclared here
(not in a function)
main/internal_functions.c:47: initializer element is not constant
main/internal_functions.c:47: (near initialization for
`php_builtin_extensions[6]')
main/internal_functions.c:48: `phpext_mysql_ptr' undeclared here (not
in a function)
main/internal_functions.c:48: initializer element is not constant
main/internal_functions.c:48: (near initialization for
`php_builtin_extensions[7]')
main/internal_functions.c:49: `phpext_ctype_ptr' undeclared here (not
in a function)
main/internal_functions.c:49: initializer element is not constant
main/internal_functions.c:49: (near initialization for
`php_builtin_extensions[8]')
*** Error code 1
make: Fatal error: Command failed for target
`main/internal_functions.lo'

OK, I see how the file "main/internal_functions.c" had been cretad by
"./configure" :

bash-2.05# grep internal_functions config.status
echo "creating main/internal_functions.c"
sh ./build/genif.sh ./main/internal_functions.c.in . "" gawk
$extensions > main/internal_functions.c


bash-2.05# pkgrm SMCgawk

bash-2.05# cp main/internal_functions.c /tmp/internal_functions.c;bad
bash-2.05# gunzip -c php-4.3.1.tar
bash-2.05# cd ../php-4.3.1
bash-2.05# CFLAGS='-DEAPI' ./configure
--with-apxs=/usr/local/apache/bin/apxs
--with-mysql=/usr/local/mysql
--with-zlib=/usr/local
--with-gd

No problem during the configure.

bash-2.05# grep internal_functions config.status
echo "creating main/internal_functions.c"
sh ./build/genif.sh ./main/internal_functions.c.in . "" nawk
$extensions > main/internal_functions.c

Here, nawk is used instead of gawk.

bash-2.05# make
bash-2.05# make install

All is OK and all work correctly.

If I make a diff on the new main/internal_functions.c and the old one
/tmp/internal_functions.c, I can see a big difference.

Guillaume,


------------------------------------------------------------------------


--
Edit this bug report at [url]http://bugs.php.net/?id=23774&edit=1[/url]