php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #35890 Cannot load libphp5.so - undefined symbol ...
Submitted: 2006-01-04 07:26 UTC Modified: 2006-01-06 03:13 UTC
From: paul at ensigma dot com dot au Assigned:
Status: Not a bug Package: *General Issues
PHP Version: 5.1.1 OS: Redhat 9.0
Private report: No CVE-ID: None
 [2006-01-04 07:26 UTC] paul at ensigma dot com dot au
Description:
------------
I compiled PHP 5.1.1 on Redhat 9.0 with the following command:

./configure --with-mysql=/usr --with-gd --with-ttf --enable-track-vars  --with-apxs2=/usr/local/apache2/bin/apxs  --with-jpeg-dir=/root/source/jpeg-6b/  --with-png-dir=/usr/local/lib/libp\
ng.a --with-zlib-dir=/usr/local/lib/zlib.a --with-tiff-dir=/usr/local/lib/libtiff.a --with-gdbm  --enable-mbstring 

When I attempt to load it into Apache 2.0.50 (via LoadModule php5_module  modules/libphp5.so), I get the following error on startup:

Starting httpd: Syntax error on line 56 of /usr/local/apache2/conf/httpd.conf:
Cannot load /usr/local/apache2/modules/libphp5.so into server: /usr/local/apache2/modules/libphp5.so: undefined symbol: php_libxml_increment_node_ptr

The machine has been running many previous version of PHP (most recently 4.3.2). I had to upgrade my libxml2 library bit this seemed to work as planned.

This looks a little like 35737 and 33004 both of which didn't come to much,... but there seem to be quite a lot of similar problems mentioned on the web so I thought I should report it. Apologies in advance I am being a clown :-)

Expected result:
----------------
Expected Apache to start without error.

Actual result:
--------------
Error on starting apache:

Starting httpd: Syntax error on line 56 of /usr/local/apache2/conf/httpd.conf:
Cannot load /usr/local/apache2/modules/libphp5.so into server: /usr/local/apache2/modules/libphp5.so: undefined symbol: php_libxml_increment_node_ptr


Running ldd I get:

[root@chef lib]# ldd -d /usr/local/apache2/modules/libphp5.so
        libcrypt.so.1 => /lib/libcrypt.so.1 (0x403fb000)
        libmysqlclient.so.14 => /usr/lib/libmysqlclient.so.14 (0x40428000)
        libttf.so.2 => /usr/lib/libttf.so.2 (0x4052b000)
        libpng12.so.0 => /usr/lib/libpng12.so.0 (0x40551000)
        libz.so.1 => /usr/lib/libz.so.1 (0x40574000)
        libjpeg.so.62 => /usr/lib/libjpeg.so.62 (0x40583000)
        libgdbm.so.2 => /usr/lib/libgdbm.so.2 (0x405a1000)
        libresolv.so.2 => /lib/libresolv.so.2 (0x405a8000)
        libm.so.6 => /lib/tls/libm.so.6 (0x405ba000)
        libdl.so.2 => /lib/libdl.so.2 (0x405dc000)
        libnsl.so.1 => /lib/libnsl.so.1 (0x405df000)
        libxml2.so.2 => /usr/local/lib/libxml2.so.2 (0x405f5000)
        libc.so.6 => /lib/tls/libc.so.6 (0x42000000)
        libnss_files.so.2 => /lib/libnss_files.so.2 (0x40700000)
        libnss_dns.so.2 => /lib/libnss_dns.so.2 (0x4070c000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)
        libpthread.so.0 => /lib/tls/libpthread.so.0 (0x40710000)
undefined symbol: php_libxml_increment_node_ptr (/usr/local/apache2/modules/libphp5.so)
undefined symbol: php_libxml_node_free_resource (/usr/local/apache2/modules/libphp5.so)
undefined symbol: php_libxml_node_decrement_resource    (/usr/local/apache2/modules/libphp5.so)
undefined symbol: php_libxml_increment_doc_ref  (/usr/local/apache2/modules/libphp5.so)
undefined symbol: php_libxml_import_node        (/usr/local/apache2/modules/libphp5.so)
undefined symbol: php_libxml_register_export    (/usr/local/apache2/modules/libphp5.so)
undefined symbol: php_format_date       (/usr/local/apache2/modules/libphp5.so)
undefined symbol: get_timezone_info     (/usr/local/apache2/modules/libphp5.so)
undefined symbol: timelib_get_time_zone_info    (/usr/local/apache2/modules/libphp5.so)
undefined symbol: timelib_time_offset_dtor      (/usr/local/apache2/modules/libphp5.so)
undefined symbol: php_pcre_replace      (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_rwrite     (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_table_set (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_table_add (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_pstrdup   (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_set_content_type   (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_get_brigade        (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_brigade_flatten   (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_brigade_cleanup   (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_table_get (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_table_elts        (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_rflush     (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_log_rerror (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_log_error  (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_add_version_component      (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_mpm_query  (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_pool_userdata_get (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_pool_cleanup_null (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_pool_cleanup_register     (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_pool_userdata_set (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_table_unset       (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_auth_type  (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_pool_cleanup_run  (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_add_common_vars    (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_add_cgi_vars       (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_palloc    (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_bucket_eos_create (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_pass_brigade       (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_update_mtime       (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_set_last_modified  (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_brigade_create    (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_hook_pre_config    (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_hook_post_config   (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_hook_handler       (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_server_root_relative       (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_sub_req_lookup_uri (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_destroy_sub_req    (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_run_sub_req        (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_get_server_version (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_loaded_modules     (/usr/local/apache2/modules/libphp5.so)
undefined symbol: unixd_config  (/usr/local/apache2/modules/libphp5.so)
undefined symbol: apr_snprintf  (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ap_server_root        (/usr/local/apache2/modules/libphp5.so)
undefined symbol: libxml_module_entry   (/usr/local/apache2/modules/libphp5.so)
undefined symbol: iconv_module_entry    (/usr/local/apache2/modules/libphp5.so)
undefined symbol: dom_module_entry      (/usr/local/apache2/modules/libphp5.so)
undefined symbol: date_module_entry     (/usr/local/apache2/modules/libphp5.so)
undefined symbol: ctype_module_entry    (/usr/local/apache2/modules/libphp5.so)
undefined symbol: pcre_module_entry     (/usr/local/apache2/modules/libphp5.so)


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2006-01-04 10:25 UTC] sniper@php.net
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.

Your configure line isn't even close to something that can work. Try ./configure --help once in your life.
 [2006-01-04 22:29 UTC] paul at ensigma dot com dot au
Sorry for reporting a non bug. I am not sure whether your parting comment is intended to be flippant or rude but either way, it is dangerous to presume that other people are idiots. I can't imagine how you think I could possibly come up with the congigure options without using ./configure --help and the configure line DOES work for 4.3.2 and 4.4.0 and most other versions back to 3.0.
 [2006-01-06 03:13 UTC] paul at ensigma dot com dot au
For those who follow,... completely removing the PHP-5.1.1 source tree (ie re-extracting the tar ball) and then running the configure/make again fixed the problems. It seems like maybe the first build created some turds that were not removed by a "make clean"?? Perhaps this was related to an old version of libxml the first time configure was run??. All very strange but working correctly now. 

P.S. As anticipated the configure command worked fine - perhaps a lesson to some that being an arrogant @*&$ is not without it's risks.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 26 01:01:30 2024 UTC