环境准备:
' z" c% F' ]. h/ G, qyum groupinstall "Development tools"
9 s7 A$ F! t+ e. w; Iyum install libxml2-devel gd-devel libmcrypt-devel libcurl-devel openssl-devel% {0 `: e1 I: P0 y( Q6 a9 F
- Z$ d6 ]2 I1 k8 S2 D软件包:
. P1 N5 ]" V) E* W; ?wget http://us3.php.net/get/php-5.6.9.tar.gz/from/cn2.php.net/mirror6 ?. n/ Y/ f7 `
tar -xvf php-5.6.9.tar.gz
3 ]. |1 E/ k5 Y' q4 m9 i% Ncd php-5.6.91 q1 c. p: _: g# Y
: {9 m, F& }7 g& G1 u0 s) T3 h' F编译安装 php 5.6.9 的参数:. Y, D2 `) ]$ |6 E; G! n
/ H0 h7 [0 V" S) }) A
[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
# A0 i5 l& U( x; Z& C0 w: c; [
4 V9 c ~* Y) Q& }% T7 vmake
. k$ ^. l1 a: y g8 T- X9 ]( Emake install5 N$ i- y: m9 J; S7 ?# R( j
--enable-maintainer-zts 此句意思有线程安全版本,开启后ZendGuardLoader不能使用!+ E0 n* L* r* i8 s8 O6 Y6 k {, w
|