PHP compilation and installation steps

Guanhui
Release: 2023-03-01 12:48:01
Original
4267 people have browsed it

PHP compilation and installation steps

PHP compilation and installation steps

PHP compilation and installation steps:

First enter the PHP official website and download the PHP source code locally ;

PHP compilation and installation steps

Then upload the PHP source code to the server and decompress the PHP source code;

Decompression command

 tar -xjvf
Copy after login

Decompression directory The content inside

PHP compilation and installation steps

#Then install the decompressed PHP source code;

If it prompts that there is any missing software, just directly (centos) yum install or (ubuntu ) apt-get install to install these compilation software. (Generally, if there is something missing, it is gcc, autoconfig and other compilation software)

./configure --prefux=/home/soft/php/  --with-config-file-path=/home/soft/php/etc
Copy after login

Finally, just add PHP to the environment variable.

vim ~/.bash_profile

Add alias = php=/home/soft/php/bin/php

php -v Test whether it works

Recommended tutorial: "PHP"

The above is the detailed content of PHP compilation and installation steps. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
php
source:php.cn
Statement of this Website
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 [email protected]
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!