heizi21 发表于 2008-09-10 13:53

configure: error: PDO_MYSQL configure failed

# ./configure --with-php-config=/usr/local/php/bin/php-config --enable-pdo --with-pdo-mysql=/usr/local/mysql/ --with-zlib-dir=/usr/local/lib
checking for egrep... grep -E
checking for a sed that does not truncate output... /bin/sed
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
checking whether gcc and cc understand -c and -o together... yes
checking for system library directory... lib
checking if compiler supports -R... no
checking if compiler supports -Wl,-rpath,... yes
checking build system type... i686-pc-linux-gnu
checking host system type... i686-pc-linux-gnu
checking target system type... i686-pc-linux-gnu
checking for PHP prefix... /usr/local/php
checking for PHP includes... -I/usr/local/php/include/php -I/usr/local/php/include/php/main -I/usr/local/php/include/php/TSRM -I/usr/local/php/include/php/Zend -I/usr/local/php/include/php/ext -I/usr/local/php/include/php/ext/date/lib
checking for PHP extension directory... /usr/local/php/lib/php/extensions/no-debug-non-zts-20060613
checking for PHP installed headers prefix... /usr/local/php/include/php
checking for re2c... re2c
checking for re2c version... 0.12.3 (ok)
checking for gawk... gawk
checking for MySQL support for PDO... yes, shared
checking for the location of libz... /usr/local/lib
checking for mysql_config... /usr/local/mysql//bin/mysql_config
checking for mysql_query in -lmysqlclient... no
checking for mysql_query in -lmysqlclient... (cached) no
configure: error: PDO_MYSQL configure failed. Please check config.log for more information.
以上是添加pdo_mysql模块出现的错误,请问各位有知道如何解决的么? php5.2.6   mysql5.0.26

ganluo960214 发表于 2016-05-30 23:46

请问 你是怎么解决的?

satrun7 发表于 2016-05-31 18:14

不使用mysql的库 ,用php官方的mysqlnd。--with-pdo-mysql=mysqlnd ,php 5.3+版本都可以。

tomac_cu 发表于 2016-07-18 15:55

hecking for mysql_query in -lmysqlclient... no
checking for mysql_query in -lmysqlclient... (cached) no

先安装mysqlclient 就好了.
页: [1]
查看完整版本: configure: error: PDO_MYSQL configure failed