search
HomeBackend DevelopmentPHP7php7.0.5 installation tutorial

php7.0.5 installation tutorial

Aug 19, 2020 am 10:46 AM
centos

Installation method of php7.0.5: First download "php-7.0.5.tar.gz"; then update the expansion package through the command "yum install epel-release"; then execute the compilation command; finally modify the configuration file That’s it.

php7.0.5 installation tutorial

Recommended: "PHP Video Tutorial"

The official version of PHP7.0 is also out today. I compiled and installed it and wrote down the installation steps. I compiled it in centos6.6 environment, as follows:

  1. Download address http://cn2.php.net/distributions/php-7.0. 5.tar.gz
  2. Install the packages required for compilation. If some packages cannot be found, please execute
yum  install epel-release  //扩展包更新包
yum  update //更新yum源

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 curl-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

  1. Execute the compilation 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  --enable-sockets --enable-bcmath --enable-xml --with-bz2 --enable-zip --with-freetype-dir=/usr/include/freetype2/

What you need to pay attention to in the above command is

The --with-mysqli parameter specifies the bin file path where mysql is located, such as: /usr/bin/mysql_config

--with-freetype-dir specified path It is /usr/include/freetype2/ If you installed freetype2 with yum

Others are based on your actual needs Just add or delete

  1. Configuration file
  2. ##
    # 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
It should be noted that in php7 www. The conf configuration file configures the port number and other information of phpfpm. If you modify the default 9000 port number, you need to change it here, and then change the nginx configuration

Start

#  /etc/init.d/php-fpm

The above is the detailed content of php7.0.5 installation tutorial. For more information, please follow other related articles on the PHP Chinese website!

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

SecLists

SecLists

SecLists is the ultimate security tester's companion. It is a collection of various types of lists that are frequently used during security assessments, all in one place. SecLists helps make security testing more efficient and productive by conveniently providing all the lists a security tester might need. List types include usernames, passwords, URLs, fuzzing payloads, sensitive data patterns, web shells, and more. The tester can simply pull this repository onto a new test machine and he will have access to every type of list he needs.

PhpStorm Mac version

PhpStorm Mac version

The latest (2018.2.1) professional PHP integrated development tool

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

MantisBT

MantisBT

Mantis is an easy-to-deploy web-based defect tracking tool designed to aid in product defect tracking. It requires PHP, MySQL and a web server. Check out our demo and hosting services.

Atom editor mac version download

Atom editor mac version download

The most popular open source editor