一、安装yaf
1.下载
wget http://pecl.php.net/get/yaf-3.0.7.tgz

2.解压安装
tar zxf yaf-3.0.7.tgz

cd yaf-3.0.7 && phpize
./configure --with-php-config=/usr/local/php/bin/php-config
make && make install

二、安装yar

1.下载
wget http://pecl.php.net/get/yar-2.0.4.tgz

2.解压安装
tar zxf yar-2.0.4.tgz
cd yar-2.0.4 && phpize
./configure --with-php-config=/usr/local/php/bin/php-config
make && make install

三,安装msgpack

1.下载
wget http://pecl.php.net/get/msgpack-2.0.2.tgz

2.解压安装
tar zxf msgpack-2.0.2.tgz
cd msgpack-2.0.2&& phpize
./configure --with-php-config=/usr/local/php/bin/php-config
make && make install

四、安装amqp(需先安装rabbitmq-c)
1.下载
wget http://pecl.php.net/get/amqp-1.9.3.tgz

2.解压安装
tar zxf amqp-1.9.3.tgz
cd amqp-1.9.3
phpize
./configure --with-php-config=/usr/local/php/bin/php-config --with-amqp --with-librabbitmq-dir=/usr/local/rabbitmq-c/
make && make install

五,安装redis
1.下载
wget http://pecl.php.net/get/redis-4.0.2.tgz

2.解压安装
tar zvxf redis-4.0.2.tgz
cd redis-4.0.2 && phpize
./configure --with-php-config=/usr/local/php/bin/php-config
make && make install

六,安装:php imagick插件

安装依赖:
yum install -y ImageMagick ImageMagick-devel

下载:
http://pecl.php.net/get/imagick-3.4.3.tgz

2.解压安装
tar zvxf imagick-3.4.3.tgz
cd imagick-3.4.3
phpize
./configure --with-php-config=/usr/local/php/bin/php-config
make && make install

六,添加拓展插件配置

#vim /usr/local/php/etc/php.ini

extension=yaf.so
yaf.environ='zaibei'
#yaf.environ='dev'
yaf.use_namespace=1

extension=msgpack.so
extension=yar.so
extension=redis.so
extension=amqp.so