0

我试图编译 mysqlnd_qc 但失败了。

我正在运行 Ubuntu 14.04.1 并已从启动板存储库https://launchpad.net/~ondrej/+archive/ubuntu/php5-5.6安装 PHP 5.6.5 。我还安装了 libmemcached-dev 以启用 mysqlnd_qc 的 memcached 功能。

这是我使用的命令:

phpize
./configure --enable-mysqlnd-qc --enable-mysqlnd-qc-memcache --enable-shared
make

配置时没有错但编译失败:

/bin/bash /home/frederick/mysqlnd_qc-1.2.0/libtool --mode=compile cc  -I. -I/home/frederick/mysqlnd_qc-1.2.0 -DPHP_ATOM_INC -I/home/frederick/mysqlnd_qc-1.2.0/include -I/home/frederick/mysqlnd_qc-1.2.0/main -I/home/frederick/mysqlnd_qc-1.2.0 -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  -DHAVE_CONFIG_H  -g -O2   -c /home/frederick/mysqlnd_qc-1.2.0/mysqlnd_qc.c -o mysqlnd_qc.lo
libtool: compile:  cc -I. -I/home/frederick/mysqlnd_qc-1.2.0 -DPHP_ATOM_INC -I/home/frederick/mysqlnd_qc-1.2.0/include -I/home/frederick/mysqlnd_qc-1.2.0/main -I/home/frederick/mysqlnd_qc-1.2.0 -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 -DHAVE_CONFIG_H -g -O2 -c /home/frederick/mysqlnd_qc-1.2.0/mysqlnd_qc.c  -fPIC -DPIC -o .libs/mysqlnd_qc.o
/home/frederick/mysqlnd_qc-1.2.0/mysqlnd_qc.c: In function 'php_mysqlnd_qc_store_result_pub':
/home/frederick/mysqlnd_qc-1.2.0/mysqlnd_qc.c:624:3: error: too few arguments to function 'qc_orig_mysqlnd_conn_methods->store_result'
   result = QC_CALL_ORIGINAL_CONN_DATA_METHOD(store_result)(conn TSRMLS_CC);
   ^
/home/frederick/mysqlnd_qc-1.2.0/mysqlnd_qc.c: In function 'php_mysqlnd_qc_use_result_pub':
/home/frederick/mysqlnd_qc-1.2.0/mysqlnd_qc.c:786:2: error: too few arguments to function 'qc_orig_mysqlnd_conn_methods->use_result'
  ret = QC_CALL_ORIGINAL_CONN_DATA_METHOD(use_result)(conn TSRMLS_CC);
  ^
/home/frederick/mysqlnd_qc-1.2.0/mysqlnd_qc.c: In function 'mysqlnd_qc_register_hooks':
/home/frederick/mysqlnd_qc-1.2.0/mysqlnd_qc.c:882:39: warning: assignment from incompatible pointer type [enabled by default]
  my_mysqlnd_conn_methods.store_result = MYSQLND_METHOD(mysqlnd_qc, store_result);
                                       ^
/home/frederick/mysqlnd_qc-1.2.0/mysqlnd_qc.c:884:37: warning: assignment from incompatible pointer type [enabled by default]
  my_mysqlnd_conn_methods.use_result = MYSQLND_METHOD(mysqlnd_qc, use_result);
                                     ^
make: *** [mysqlnd_qc.lo] Error 1

我试图编译稳定版本但也失败了。怎么了?请帮助我,谢谢!

4

1 回答 1

2

mysqlnd_qc-1.2.0 与 PHP 5.6 不兼容

您可以使用主干上的最新源代码。 http://svn.php.net/viewvc/pecl/mysqlnd_qc/trunk/

他们的更改日志。 https://lists.fedoraproject.org/pipermail/scm-commits/Week-of-Mon-20140317/1210988.html

于 2015-02-04T17:56:33.593 回答