PHP编译动态文件(centos)
Cannot find autoconf. Please check your autoconf installation and the $PHP_AUTOCONF environment variable. Then, rerun this script.
解决方法:yum install -y autoconf
configure: error: Please reinstall the libcurl distribution -
easy.h should be in /include/curl/
解决方法:yum install -y libcurl libcurl-devel
PHP编译动态库curl.so步骤:
(1)cd到php的源码目录的curl下
cd /usr/local/src/php-5.4.43/curl
(2)生成configure文件
/usr/local/php/bin/phpize
(3)./configure –with-php-config=/usr/local/php/bin/config
(4)make
(5)make install
(6)编辑php.ini文件(/usr/local/php/etc/php.ini),找到;extension在其末尾添加extension=curl.so
查看php加载了哪些动态库:
grep ‘^extension=’ /usr/local/php/etc/php.ini