Hi all,
Here are two branches that improve extension loading mechanisms and remove
dusty old features not used any more.
No BC or nothing, though perhaps some Windows support tricks to add ?
Thoughts ?
https://github.com/jpauli/php-src/extensions_improvementshttps://github.com/jpauli/php-src/compare/extensions_improvements
https://github.com/jpauli/php-src/tree/remove_old_php4_dl
Julien.Pauli
hi,
Hi all,
Here are two branches that improve extension loading mechanisms and remove
dusty old features not used any more.No BC or nothing, though perhaps some Windows support tricks to add ?
Thoughts ?
https://github.com/jpauli/php-src/extensions_improvementshttps://github.com/jpauli/php-src/compare/extensions_improvements
I'm not sure about the zend_error usage, I remember some issues about
it (not always initialized and similar issues). Dmitry, do you
remember why we used fprintf there? :)
Cheers,
Pierre
@pierrejoye
Hi,
-
I didn't get why do we need fprintf("Loaded/Unloaded extension"). It'll
break all the tests in DEBUG mode -
zend_error() may work through SAPI handler (e.g. for FastCGI sapi it may
try to send error message to WebServer while request context is not
initialized yet). I think it must work now, but should be double checked.
Thanks. Dmitry.
hi,
Hi all,
Here are two branches that improve extension loading mechanisms and
remove
dusty old features not used any more.No BC or nothing, though perhaps some Windows support tricks to add ?
Thoughts ?
https://github.com/jpauli/php-src/extensions_improvements<
https://github.com/jpauli/php-src/compare/extensions_improvements>I'm not sure about the zend_error usage, I remember some issues about
it (not always initialized and similar issues). Dmitry, do you
remember why we used fprintf there? :)Cheers,
Pierre
@pierrejoye
Hi,
- I didn't get why do we need fprintf("Loaded/Unloaded extension"). It'll
break all the tests in DEBUG mode
Great catch
- zend_error() may work through SAPI handler (e.g. for FastCGI sapi it
may try to send error message to WebServer while request context is not
initialized yet). I think it must work now, but should be double checked.Thanks. Dmitry.
Ok, Do you think as well we could build specific tests for this part ?
We could pre-build some shared objects with different known behavior, and
test for loading extensions and Zend extensions for example.
Julien.Pauli
Hi,
I didn't get why do we need fprintf("Loaded/Unloaded extension"). It'll
break all the tests in DEBUG modezend_error() may work through SAPI handler (e.g. for FastCGI sapi it
may try to send error message to WebServer while request context is not
initialized yet). I think it must work now, but should be double checked.
After several tests on CLI and CGI, I see no bug, but starting cgi makes
the error message being printed twice :
/tmp/bin/php-cgi -dzend_extension=foo.so -dtrack_errors=1
PHP Warning: /tmp/lib/php/extensions/debug-non-zts-20121212/foo.so
doesn't appear to be a valid Zend Engine extension
- in Unknown on line 0*
Unknown(0) : Warning -
/tmp/lib/php/extensions/debug-non-zts-20121212/foo.so doesn't appear to be
a valid Zend Engine extension
PHP Warning: /tmp/lib/php/extensions/debug-non-zts-20121212/foo.so appear
to be a PHP extension, try to load it using extension=foo.so
- in Unknown on line 0*
Unknown(0) : Warning -
/tmp/lib/php/extensions/debug-non-zts-20121212/foo.so appear to be a PHP
extension, try to load it using extension=foo.so
Julien.Pauli
Hi,
I didn't get why do we need fprintf("Loaded/Unloaded extension").
It'll
break all the tests in DEBUG modezend_error() may work through SAPI handler (e.g. for FastCGI sapi it
may try to send error message to WebServer while request context is not
initialized yet). I think it must work now, but should be double checked.After several tests on CLI and CGI, I see no bug, but starting cgi makes
the error message being printed twice :/tmp/bin/php-cgi -dzend_extension=foo.so -dtrack_errors=1
PHP Warning: /tmp/lib/php/extensions/debug-non-zts-20121212/foo.so
doesn't appear to be a valid Zend Engine extension
- in Unknown on line 0*
Unknown(0) : Warning -
/tmp/lib/php/extensions/debug-non-zts-20121212/foo.so doesn't appear to be
a valid Zend Engine extensionPHP Warning: /tmp/lib/php/extensions/debug-non-zts-20121212/foo.so appear
to be a PHP extension, try to load it using extension=foo.so
- in Unknown on line 0*
Unknown(0) : Warning -
/tmp/lib/php/extensions/debug-non-zts-20121212/foo.so appear to be a PHP
extension, try to load it using extension=foo.soJulien.Pauli
I would guess that both log_errors and display_errors is enabled and the
error_log is set to STDERR
or STDOUT
--
Ferenc Kovács
@Tyr43l - http://tyrael.hu