ubuntu 14.04编译安装PHP5.3 带PHP-FPM
安装命令
wget http://cn2.php.net/distributions/php-5.3.29.tar.gz tar -zxvf php-5.3.8.tar.gz cd php-5.3.29 sudo apt-get install libxml2 libxml2-dev libevent-1.4-2 libevent-dev bzip2 libbz2-dev libcurl3-gnutls libcurl4-gnutls-dev libpng12-0 libpng12-dev libjpeg62 libjpeg62-dev libfreetype6 libfreetype6-dev libmcrypt4 libmcrypt-dev zlib1g-dev libtidy-dev libmysqlclient-dev libopenssl-dev libsnmp-dev -y ./configure --prefix=/usr/local/php --enable-fpm --with-libevent-dir=/usr --with-mcrypt=/usr/local/libmcrypt --with-zlib --enable-mbstring --with-openssl --with-mysql --with-mysqli --with-mysql-sock --with-gd --with-jpeg-dir=/usr/lib --enable-gd-native-ttf --without-sqlite --enable-pdo --with-pdo-mysql --with-gettext --with-curl --with-pdo-mysql --enable-sockets --enable-bcmath --enable-xml --with-bz2 --with-gettext --with-snmp --enable-zip --with-snmp make make install php5.3.8默认包含php-fpm, php-fpm的配置文件php-fpm.conf在/usr/local/php/etc <========当然要看你装php到了那里 php-fpm.conf的文件名这里为php-fpm.conf.default #cp php-fpm.conf.default php-fpm.conf <========复制一份并重命名 php-fpm在/usr/local/php/sbin/下 #/usr/local/php/sbin/php-fpm ========启动php-fpm |