下面以最新的php-5.3.10为例进行安装。 1wget http://cn.php.net/distributions/php-5.3.10.tar.gz 2tar -zxvf php-5.3.10.tar.gz 3cd php-5.3.10 4./configure --prefix=/usr/local/php --with-config-file-path=/usr/local/php/etc --with-mysql=/usr/local/mysql --with-mysqli=/usr/local/mysql/bin/mysql_config --with-iconv-dir --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib --with-libxml-dir --enable-xml --disable-rpath --enable-bcmath --enable-shmop --enable-sysvsem --enable-inline-optimization --with-curl --with-curlwrappers --enable-mbregex --enable-fpm --enable-mbstring --with-mcrypt --with-gd --enable-gd-native-ttf --with-openssl --with-mhash --enable-pcntl --enable-sockets --with-ldap --with-ldap-sasl --with-xmlrpc --enable-zip --enable-soap 上面的具体参数可以使用./configure –help查看 1make ZEND_EXTRA_LIBS='-liconv' 2make test 3make && make install (此处最好分开做,因为make的时候会有报错出现。) 我在上面的make时就报了……
Continue reading