При стандартной компиляции может вылезти ошибка:
# make
/bin/sh /usr/src/memcached-2.2.0/libtool --mode=compile cc -I/usr/lib64/php5.6/include/php -I. -I/usr/src/memcached-2.2.0 -DPHP_ATOM_INC -I/usr/src/memcached-2.2.0/include -I/usr/src/memcached-2.2.0/main -I/usr/src/memcached-2.2.0 -I/usr/lib64/php5.6/include/php -I/usr/lib64/php5.6/include/php/main -I/usr/lib64/php5.6/include/php/TSRM -I/usr/lib64/php5.6/include/php/Zend -I/usr/lib64/php5.6/include/php/ext -I/usr/lib64/php5.6/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /usr/src/memcached-2.2.0/php_memcached.c -o php_memcached.lo
/usr/src/memcached-2.2.0/libtool: line 482: CDPATH: command not found
libtool: Version mismatch error. This is libtool 2.4.2, but the
libtool: definition of this LT_INIT comes from an older release.
libtool: You should recreate aclocal.m4 with macros from libtool 2.4.2
libtool: and run autoconf again.
make: *** [php_memcached.lo] Error 63
Это лечится запуском
aclocal && libtoolize --force && autoreconf
между phpize и ./configure
Скрипт установки:
--------------------------------------------------------------------------------------------------
#!/bin/bash
cd /usr/src
wget http://pecl.php.net/get/memcached-2.2.0.tgz
tar xvf memcached-2.2.0.tgz
cd memcached-2.2.0
phpize
aclocal && libtoolize --force && autoreconf
./configure
make
make install
if [ ! -f /etc/php/fpm-php5.6/ext/memcached.ini ];
then
echo "extension=memcached.so" > /etc/php/fpm-php5.6/ext/memcached.ini
fi
cd /etc/php/fpm-php5.6/ext-active
ln -s ../ext/memcached.ini memcached.ini
if [ ! -f /etc/php/cli-php5.6/ext/memcached.ini ];
then
echo "extension=memcached.so" > /etc/php/fpm-php5.6/ext/memcached.ini
fi
cd /etc/php/cli-php5.6/ext-active
ln -s ../ext/memcached.ini memcached.ini