首页 > 代码库 > PHP 5.6编译安装
PHP 5.6编译安装
yum install openssl openssl-devel libxml2-deve libxml2 bzip2 bzip2-devel curl-devel php-mcrypt libmcrypt
libmcrypt-devel readline-devel
wget http://mirrors.sohu.com/php/php-5.6.31.tar.gz
tar xzvf php-5.6.31.tar.gz
cd php-5.6.31.tar.gz
1. 配置编译选项
./configure --prefix=/usr/local/php --with-config-file-path=/usr/local/php/etc --enable-inline-optimization --disable-debug --disable-rpath
--enable-shared --enable-opcache --enable-fpm --with-fpm-user=www --with-fpm-group=www --with-mysql=mysqlnd --with-mysqli=mysqlnd
--with-pdo-mysql=mysqlnd --with-gettext --enable-mbstring --with-iconv --with-mcrypt --with-mhash --with-openssl --enable-bcmath
--enable-soap --with-libxml-dir --enable-pcntl --enable-shmop --enable-sysvmsg --enable-sysvsem --enable-sysvshm --enable-sockets
--with-curl --with-zlib --enable-zip --with-bz2 --with-readline
2. 编译PHP
make
3. 安装PHP
make install
PHP 5.6编译安装