dt4233 2010-03-05 09:44
浏览 130
已采纳

PHP错误:libphp5.so:未定义的符号:_estrndup [关闭]

I compile Apache-MySQL-PHP by hand to build a custom install using the configure options from below. When I start apache it fails to start and adds the below error in the error_log.
* Apache 2
* Mysql 5.0
* PHP 5.1
* CentOS Linux 5.4 * GCC compiler

the error in apache log

httpd: Syntax error on line 54 of /opt/clamp/etc/httpd.conf: Cannot load /opt/clamp/modules/libphp5.so into server: /opt/clamp/modules/libphp5.so: undefined symbol: _estrndup

the ./configure options

APACHE ./configure \ --prefix=/opt/clamp \ --sysconfdir=/opt/clamp/etc \ --enable-auth-dbm \ --enable-cern-meta \ --enable-auth-digest \ --enable-charset-lite \ --enable-deflate \ --enable-expires \ --enable-cache \ --enable-disk-cache \ --enable-file-cache \ --enable-headers \ --enable-info \ --enable-mime-magic \ --enable-proxy \ --enable-proxy-ajp \ --enable-proxy-balancer \ --enable-proxy-connect \ --enable-proxy-ftp \ --enable-proxy-http \ --enable-rewrite \ --enable-so \ --enable-ssl

MYSQL ./configure \ --prefix=/opt/clamp \ --sysconfdir=/opt/clamp/etc \ --libexecdir=/opt/clamp/sbin \ --localstatedir=/opt/clamp/var \ --with-unix-socket-path=/opt/clamp/tmp/mysql.sock \ --enable-thread-safe

PHP ./configure \ --prefix=/opt/clamp \ --sysconfdir=/opt/clamp/etc \ --with-apxs2=/opt/clamp/bin/apxs \ --with-config-file-path=/opt/clamp/etc/php.conf \ --with-mysql=/opt/clamp \ --with-mysqli=/opt/clamp/bin/mysql_config \ --enable-force-cgi-redirect \ --disable-cgi \ --with-zlib \ --with-gettext \ --with-gdbm \ --with-ldap \ --with-ldap-sasl \ --enable-zip \ --with-bz2 \ --with-gd \ --with-jpeg-dir=/usr \ --with-png-dir=/usr

  • 写回答

3条回答 默认 最新

  • dongteng0748 2010-04-20 16:06
    关注

    It seems that I wasn't building PHP's GD library right, building PHP with the following options worked (no more error):

    cd php-5.2.13/ ./configure \ --prefix=/opt/clamp \ --sysconfdir=/opt/clamp/etc \ --with-apxs2=/opt/clamp/bin/apxs \ --with-config-file-path=/opt/clamp/etc/php.conf \ --disable-debug \ --with-pic \ --disable-rpath \ --without-pear \ --with-bz2 \ --with-curl \ --with-freetype-dir=/usr \ --with-png-dir=/usr \ --enable-gd-native-ttf \ --without-gdbm \ --with-gettext \ --with-gmp \ --with-iconv \ --with-jpeg-dir=/usr \ --with-openssl \ --with-pspell \ --with-zlib \ --with-layout=GNU \ --enable-exif \ --enable-ftp \ --enable-magic-quotes \ --enable-sockets \ --enable-sysvsem --enable-sysvshm --enable-sysvmsg \ --enable-wddx \ --with-kerberos \ --enable-ucd-snmp-hack \ --enable-shmop \ --enable-calendar \ --without-sqlite \ --enable-force-cgi-redirect \ --enable-pcntl \ --with-imap --with-imap-ssl \ --enable-mbstring \ --enable-mbregex \ --with-ncurses \ --with-gd \ --enable-bcmath \ --with-xmlrpc \ --with-ldap --with-ldap-sasl \ --with-mysql=/opt/clamp \ --with-mysqli=/opt/clamp/bin/mysql_config \ --enable-dom \ --with-pgsql \ --enable-soap \ --enable-xmlreader --enable-xmlwriter \ --enable-fastcgi make make install

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(2条)

报告相同问题?

悬赏问题

  • ¥20 有关区间dp的问题求解
  • ¥15 多电路系统共用电源的串扰问题
  • ¥15 slam rangenet++配置
  • ¥15 有没有研究水声通信方面的帮我改俩matlab代码
  • ¥15 对于相关问题的求解与代码
  • ¥15 ubuntu子系统密码忘记
  • ¥15 信号傅里叶变换在matlab上遇到的小问题请求帮助
  • ¥15 保护模式-系统加载-段寄存器
  • ¥15 电脑桌面设定一个区域禁止鼠标操作
  • ¥15 求NPF226060磁芯的详细资料