Centos7 Source Installation Php7

Source: Internet
Author: User

System: centos7.2

PHP Version: php7.0.0

Pre-installation work:

Yum install gcc make crul-devel libxslt-devel gd-devel libjpeg-devel libpng libpng-devel libxml2-devel bzip2-devel libcurl -devel–y #如果下面 Configuration compilation error please yum install dependent packages

Wget-o/etc/yum.repos.d/epel.repo Http://mirrors.aliyun.com/repo/epel-6.repo

Yum-y Install libmcrypt-devel mcytpt mhash libxslt-devel

Installing Libiconv

Tar XF libiconv-1.14.tar.gz

CD libiconv-1.14

./configure--prefix=/usr/lcoal/libiconv

Make && make install

Unzip the installation:

Tar XF php-7.0.0.tar.gz

CD php-7.0.0/

./configure --prefix=/usr/local/php7 --with-fpm-user=nginx --with-fpm-group=nginx -- with-bz2 --with-curl --with-gd --with-mcrypt --with-openssl --with-mhash -- with-jpeg-dir --with-png-dir --with-freetype-dir --with-iconv-dir=/usr/local/libiconv -- with-gettext --with-libxml-dir --with-zlib --with-xmlrpc --with-pcre-regex -- with-pear --with-pdo-mysql=mysqlnd --with-mysql=mysqlnd --with-mysqli=mysqlnd -- With-libdir=lib64 --enable-dom --enable-xml --enable-fpm --enable-bcmath --enable-ftp  --enable-sockets --disable-ipv6 --enable-mbregex --enable-mbstring --enable-calendar  --enable-gd-native-ttf --enable-static --enable-fpm --enable-bcmath --enable-libxml  --enable-inline-optimization --enable-mbregex --enable-opcache --enable-pcntl -- enable-shmop --enable-soap --enable-sockets --enable-sysvsem --enable-zip make && make installcp  php.ini-production /usr/local/php7/lib/php.inicp /usr/local/php7/etc/php-fpm.conf.default   /usr/local/php7/etc/php-fpm.confcp /usr/local/php7/etc/php-fpm.conf.default /usr/local/php7/ etc/php-fpm.confcp /usr/local/php7/etc/php-fpm.d/www.conf.default /usr/local/php7/etc/php-fpm.d/ www.conf#php-fpm.conf  references the *.conf  configuration file in this directory and modifies the startup user. Port number, etc. start/etc/init.d/php-fpm stop pkill php-fpm   or  ps -ef |grep php-fpm |awk   ' {print $2} '  |xargs kill



This article is from the "Jinchuang" blog, make sure to keep this source http://jinchuang.blog.51cto.com/8690689/1897385

Centos7 Source Installation Php7

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.