[PHP]CentOS6.5源码安装PHP5.3.3

下载源码文件:php-5.3.3.zip

wget http://ihoiwan.com/content/uploadfile/201611/fb191479359246.zip

解压文件,进入到源码目录

需要先安装一些库


yum install libevent libevent-devel libpng-static libpng libpng-devel libXpm-devel libjpeg libjpeg-devel libmcrypt libmcrypt-devel libtool-ltdl libtool-ltdl-devel
ln -s /usr/lib64/libpng.so /usr/lib/libpng.so
ln -s /usr/lib64/libjpeg.so /usr/lib/libjpeg.so
ln -s /usr/lib64/libXpm.so /usr/lib/libXpm.so
./configure --prefix=/usr/local/php --with-config-file-path=/etc/php --enable-fpm --enable-pcntl  --enable-sockets --enable-sysvmsg --enable-sysvsem  --enable-sysvshm --enable-shmop --enable-zip --enable-ftp --enable-soap --enable-xml --enable-mbstring --disable-rpath --disable-debug --enable-fileinfo --with-mysql=mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd --with-pcre-regex --with-iconv --with-zlib --with-mcrypt --with-gd --with-openssl --with-mhash --with-xmlrpc --with-curl --with-imap-ssl


配置通过后:


make -j8


报错:

/usr/bin/ld: cannot find -lxxx

说明有些库还有没安装,上面的yum已经安装了大部分的库,但是每个人的系统环境都不一样,遇到此类问题建议

yum search lxxx

找到正确的包以后安装。


make后还有可能遇到以下错误:

PEAR package PHP_Archive not installed: generated phar will require PHP's phar extension be enabled.

可以先make install

然后按照下面下载pear安装包并安装:

wget http://pear.php.net/go-pear.phar

php go-pear.phar


NOTE:安装oci8

./configure --with-oci8=instantclient,/usr/lib/oracle/11.2/client64/lib



版权所有:《Hoiwan's 》 => 《[PHP]CentOS6.5源码安装PHP5.3.3
本文地址:http://ihoiwan.com/?post=32
除非注明,文章均为 《Hoiwan's 》 原创,欢迎转载!转载请注明本文地址,谢谢。

评论:

nbjzdlGew
2017-08-03 04:35
topwb38q3l</br>
no credit check payday loans</br>
<a href="http://paydayloans2017.com"> payday loans online no credit check</a> </br>
&lt;a href=&quot;http://paydayloansonline2017.com&quot;&gt; payday loans&lt;/a&gt; </br>
[url=http://paydayloansonline2017.com]payday loans online no credit check[/url] </br>
same day payday loans

发表评论: