环境准备:. }& C# }/ ?6 G
yum groupinstall "Development tools", k' j$ i1 T5 x1 j: l: o
yum install libxml2-devel gd-devel libmcrypt-devel libcurl-devel openssl-devel
( V& a& A) \* ]) W* c) b9 w- ~# z8 M0 q$ R
软件包:; W& n- a; r' ~8 B) k( h5 j
wget http://us3.php.net/get/php-5.6.9.tar.gz/from/cn2.php.net/mirror
0 P# v+ f0 Q6 rtar -xvf php-5.6.9.tar.gz
) y$ {" S8 |/ z$ m1 ^+ g2 L4 acd php-5.6.9
2 Q, s$ ~1 V6 G* d0 ~8 g2 n+ r$ Q* r8 W& G1 t3 v7 y5 m
编译安装 php 5.6.9 的参数:
4 ?6 u7 M- i* P- e( y( q9 A; n( |6 h$ E6 M
[Bash shell] 纯文本查看 复制代码
./configure --prefix=/webserver/php-5.6.9 --with-config-file-path=/webserver/php-5.6.9/etc --with-mysql=mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd --with-zlib --with-curl --with-ldap --with-imap --with-kerberos --with-imap-ssl --with-gettext --with-gd --enable-gd-native-ttf --with-freetype-dir --with-jpeg-dir --with-png-dir --with-openssl --with-iconv=/usr/local --with-pcre-dir --with-mhash --with-mcrypt --with-xmlrpc --with-imap --enable-xml --enable-ftp --enable-mbstring --enable-soap --enable-sockets --enable-fpm --enable-zip --disable-debug --enable-calendar --enable-static --enable-inline-optimization --enable-wddx --enable-opcache --enable-bcmath --enable-shmop --enable-sysvsem --enable-mbregex --enable-pcntl --without-pear --enable-ctype
8 E" i! D3 B: R% @+ K" x
3 E$ E6 Z3 x0 b( |3 [& q) f
make5 s( Z' j$ X( c
make install& z7 f/ o/ |6 b3 K" w5 a) S% z
--enable-maintainer-zts 此句意思有线程安全版本,开启后ZendGuardLoader不能使用!
9 _' y$ G! r: @, m7 ~! w7 @; h |