我已经安装了memcached,libmemcached和brew,下载了memcached PECL扩展,编译它,按照本教程 - > https://donatstudios.com/OS-X-Mavericks-Memcached-PHP-Extension-Installation
然后我将memcached.so复制到MAMP的扩展名dir:
cp /tmp/memcached/memcached-2.2.0/memcached-2.2.0/modules/memcached.so /Applications/MAMP/bin/php/php5.6.2/lib/php/extensions/no-debug-non-zts-20131226/
并将行extension = memcached.so添加到/Applications/MAMP/bin/php/php5.6.2/conf/php.ini
,
根据MAMP phpinfo,这是我的PHP conf文件
但是我在MAMP / logs / php_error.log中收到以下错误:
[19-Nov-2014 09:40:16 Europe/Berlin] PHP Warning: PHP Startup: memcached: Unable to initialize module
Module compiled with module API=20121212
PHP compiled with module API=20131226
These options need to match
in Unknown on line 0
我的配置有什么问题?
如何解决并安装此memcached扩展一次???
答案 0 :(得分:1)
感谢这两页:
Having problems while try to install OAUTH with PECL in MAMP on mac OS lion
和
http://verysimple.com/2013/11/05/compile-php-extensions-for-mamp/
答案 1 :(得分:0)
brew install memcached
OR
sudo pecl install memcached