环境准备:& R4 s" m3 ?5 |( ~
yum groupinstall "Development tools"
% Y9 R9 T( B! J" _! m- wyum install libxml2-devel gd-devel libmcrypt-devel libcurl-devel openssl-devel
: b: H4 `) ?" {8 X5 r) W7 y
# k1 C" A& K: p% |软件包:; T( z) e$ y. f) i6 y
wget http://us3.php.net/get/php-5.6.9.tar.gz/from/cn2.php.net/mirror
% u" a& @) B7 A2 Z* z5 d& Btar -xvf php-5.6.9.tar.gz9 L( h' x, h$ k6 e- O* Y
cd php-5.6.9 V- }- i, T2 @5 h7 d: ]
* R4 y$ p2 [6 ~; U0 s
编译安装 php 5.6.9 的参数:
9 R6 v5 ~3 w, ?) F! |! h$ X! ~1 y0 V% P4 O# s& V0 o- A6 g
[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
, E- K5 ], C) [; w8 q& ^7 k( g
+ J4 b6 N3 i9 ~
make
, U6 C5 _0 q, W$ pmake install/ ?% B* J! r. {0 b V8 g
--enable-maintainer-zts 此句意思有线程安全版本,开启后ZendGuardLoader不能使用!! ?: n1 L) M7 N2 a, ?1 A( N+ b. d0 _
|