linux下编译安装memcache

源码官网:http://pecl.php.net/package/

 

/usr/local/php/bin/phpize --with-php-config=/usr/local/php/bin/php-config

运行/usr/local/webserver/php/bin/phpize时出现: 
Configuring for: 
PHP Api Version:         20041225 
Zend Module Api No:      20060613 
Zend Extension Api No:   220060519 
Cannot find autoconf. Please check your autoconf installation and the 
$PHP_AUTOCONF environment variable. Then, rerun this script. 
根据网上的解决办法是: yum install m4 ;yum install autoconf

 

./configure --with-php-config=...

make & make install

重要一步:把生成的.so扩展,在php.ini里引入

 extension=下面这个路径/memcache.so

最后重启apache

 

 

On
extension_dir /usr/local/php/lib/php/extensions/no-debug-zts-20121212
posted on 2016-01-03 17:11  阿卡贝拉  阅读(66)  评论(0)    收藏  举报