1 Between PHP 4.0.6 and 4.1.0, the Zend module struct changed in a way
2 that broke both source and binary compatibility. If you are
3 maintaining a third party extension, here's how to update it:
5 If this was your old module entry:
7 zend_module_entry foo_module_entry = {
8 "foo", /* extension name */
9 foo_functions, /* extension function list */
10 NULL, /* extension-wide startup function */
11 NULL, /* extension-wide shutdown function */
12 PHP_RINIT(foo), /* per-request startup function */
13 PHP_RSHUTDOWN(foo), /* per-request shutdown function */
14 PHP_MINFO(foo), /* information function */
15 STANDARD_MODULE_PROPERTIES
18 Here's how it should look if you want your code to build with PHP
21 zend_module_entry foo_module_entry = {
22 #if ZEND_MODULE_API_NO >= 20010901
23 STANDARD_MODULE_HEADER,
25 "foo", /* extension name */
26 foo_functions, /* extension function list */
27 NULL, /* extension-wide startup function */
28 NULL, /* extension-wide shutdown function */
29 PHP_RINIT(foo), /* per-request startup function */
30 PHP_RSHUTDOWN(foo), /* per-request shutdown function */
31 PHP_MINFO(foo), /* information function */
32 #if ZEND_MODULE_API_NO >= 20010901
33 FOO_VERSION, /* extension version number (string) */
35 STANDARD_MODULE_PROPERTIES
38 If you don't care about source compatibility with earlier PHP releases
39 than 4.1.0, you can drop the #if/#endif lines.