Berkeley DB XML and PHP 5.3
737935Nov 30 2009 — edited Jun 2 2010Hi,
I'm trying to compile BDB XML for PHP 5.3 on openSUSE 11.2. When trying to compile the db4 PHP module, I get (the output goes on with warnings about the string -> char* conversion, I skipped them here)
g++ -I. -I/build/dbxml-2.5.13/db-4.8.24/php_db4 -DPHP_ATOM_INC -I/build/dbxml-2.5.13/db-4.8.24/php_db4/include -I/build/dbxml-2.5.13/db-4.8.24/php_db4/main -I/build/dbxml-2.5.13/db-4.8.24/php_db4 -I/usr/include/php5 -I/usr/include/php5/main -I/usr/include/php5/TSRM -I/usr/include/php5/Zend -I/usr/include/php5/ext -I/usr/include/php5/ext/date/lib -I/opt/bdbxml/include -DHAVE_CONFIG_H -g -O2 -c /build/dbxml-2.5.13/db-4.8.24/php_db4/db4.cpp -fPIC -DPIC -o .libs/db4.o
/build/dbxml-2.5.13/db-4.8.24/php_db4/db4.cpp:193: warning: deprecated conversion from string constant to 'char*'
/build/dbxml-2.5.13/db-4.8.24/php_db4/db4.cpp:342: error: 'second_arg_force_ref' was not declared in this scope
/build/dbxml-2.5.13/db-4.8.24/php_db4/db4.cpp:342: error: 'second_arg_force_ref' was not declared in this scope
/build/dbxml-2.5.13/db-4.8.24/php_db4/db4.cpp:351: error: too many initializers for 'zend_function_entry'
...
The dbxml module does not compile either:
g++ -I. -I/build/dbxml-2.5.13/dbxml/src/php -DPHP_ATOM_INC -I/build/dbxml-2.5.13/dbxml/src/php/include -I/build/dbxml-2.5.13/dbxml/src/php/main -I/build/dbxml-2.5.13/dbxml/src/php -I/usr/include/php5 -I/usr/include/php5/main -I/usr/include/php5/TSRM -I/usr/include/php5/Zend -I/usr/include/php5/ext -I/usr/include/php5/ext/date/lib -I/opt/bdbxml/include -I/build/dbxml-2.5.13/db-4.8.24/php_db4 -I/include -DHAVE_CONFIG_H -g -O2 -c /build/dbxml-2.5.13/dbxml/src/php/php_dbxml.cpp -fPIC -DPIC -o .libs/php_dbxml.o
In file included from /build/dbxml-2.5.13/dbxml/src/php/php_dbxml.cpp:10:
/build/dbxml-2.5.13/dbxml/src/php/php_dbxml_int.hpp: In function 'void hackthe_method_table(zend_function_entry*)':
/build/dbxml-2.5.13/dbxml/src/php/php_dbxml_int.hpp:221: error: invalid conversion from 'const char*' to 'char*'
/build/dbxml-2.5.13/dbxml/src/php/php_dbxml_int.hpp:221: error: initializing argument 1 of 'void zend_str_tolower(char*, unsigned int)'
...
Is this a known limitation of the current release or am I doing anything wrong? Is there a patch available fixing the PHP integration?
Thanks!
Philipp