�##得到php7的最新代码: from https://wiki.php.net/phpng
git clone https://git.php.net/repository/php-src.git
##编译源代码:
./configure \
--prefix=/opt/php7 \
--with-config-file-path=/opt/php7/etc \
--with-config-file-scan-dir=/opt/php7/etc/conf.d \
\
--enable-opcache \
--enable-fpm \
--enable-pdo \
--enable-sockets \
--enable-pcntl \
--enable-bcmath \
--enable-mbstring \
--enable-zip \
--enable-calendar \
--enable-sysvmsg \
--enable-sysvsem \
--enable-sysvshm \
--with-mysqli \
--with-pdo-mysql \
--with-pdo-sqlite \
--with-iconv \
--with-gettext \
--with-openssl \
--with-mhash \
--with-mcrypt \
--with-curl \
--with-pcre-regex \
--with-zlib-dir=/usr \
--with-xpm-dir=/usr \
--with-gettext=/usr \
--with-zlib=/usr \
--with-pear \
--with-readline
##编译redis插件:
git clone https://github.com/edtechd/phpredis
<php7 bin>/phpize
./configure --with-php-config=<php7 bin>/php-config
./configure ....
make...
##编译memcached插件:
git clone https://github.com/php-memcached-dev/php-memcached
git checkout php7 -b