PHP7.0 official version also came out, today compiled installed a bit, write down the installation steps, I was compiled in the centos6.6 environment, as follows:
Download Address http://cn2.php.net/distributions/php-7.0.5.tar.gz Install the package required for compilation, such as Meet some of the package can not find the please execute first
Yum Install epel-release //Expansion pack update package
Yum update //update yum source
And then execute the following command
Yum install-y gcc gcc-c++ make zlib zlib-devel pcre pcre-devel libjpeg libjpeg-devel libpng libpng-devel freetype Freetype-devel libxml2 libxml2-devel glibc glibc-devel glib2 glib2-devel bzip2 bzip2-devel ncurses ncurses-devel Curl cur L-devel e2fsprogs e2fsprogs-devel krb5 krb5-devel OpenSSL openssl-devel openldap openldap-devel Nss_ldap Openldap-clients openldap-servers libmcrypt libmcrypt-devel libxpm-devel
Make & make Install
Execute compile command
./configure--prefix=/usr/local/php--enable-fpm --with-mcrypt=/usr/local/libmcrypt--with-zlib- Enable-mbstring--enable-pcntl--with-openssl --enable-soap --with-pear --with-png-dir -- With-pcre-regex --enable-mysqlnd \
--with-mysqli=mysqlnd \
--with-pdo-mysql=mysqlnd \
With-mysql-sock=/var/lib/mysql/mysql.sock --with-gd--with-jpeg-dir=/usr/lib--enable-gd-native-ttf -- With-gettext--with-curl
The note in the above command is that the--WITH-MYSQLI parameter specifies the bin file path where MySQL resides:/usr/bin/mysql_config
--with-freetype-dir the path specified is/usr/include/freetype2/If you are yum installed Freetype2
Other depending on your actual need to delete and then
configuration file
# CP Php.ini-development/usr/local/php/lib/php.ini # cp/usr/local/php/etc/php-fpm.conf.default/usr/local/php/etc/ Php-fpm.conf
# cp/usr/local/php/etc/php-fpm.d/www.conf.default/usr/local/php/etc/php-fpm.d/www.conf # cp-r./SAPI/FPM/PHP-FPM/ etc/init.d/php-fpm
Note that PHP7 www.conf This configuration file configuration phpfpm port number, and so on, if you modify the default 9000 port number should be changed here, and then change the Nginx configuration
Start#/ETC/INIT.D/PHP-FPM
Students can visit this classmate's blog for more details http://blog.csdn.net/21aspnet/article/details/47708763