php版本:5.3.1,作業系統:centos5.4
手動編譯安裝gd,然後在安裝php時指定gd安裝路徑,configure通過,make通過,make test無法通過:
imagecopyresampled() [ext/gd/tests/imagecopyresampled_basic.phpt] (warn:ing:require_once(skipif_imagetype.inc):failed to open stream:no such file or directory in /usr/local/php-5.3.1/ext/gd/tests/imagecopyresampled_basic.skip.php on line 3)
imagedashedline() [ext/gd/tests/imagedashedline_basic.phpt] (warn:ing:require_once(skipif_imagetype.inc):failed to open stream:no such file or directory in /usr/local/php-5.3.1/ext/gd/tests/imagedashedline_basic.skip.php on line 3)
imageploygon() [ext/gd/tests/imagepolygon_basic.phpt] (warn:ing:require_once(skipif_imagetype.inc):failed to open stream:no such file or directory in /usr/local/php-5.3.1/ext/gd/tests/imagepolygon_basic.skip.php on line 3)
via [ext/pdo_sqlite/tests/common.phpt]
sqlite pdo common:bug #34630 (inserting streams as lobs) [ext/pdo_sqlite/tests/bug_34630.phpt] (warn:xfail section but test passes)
via [ext/pdo_sqlite/tests/common.phpt]
sqlite pdo common:bug #34630 (inserting streams as lobs) [ext/pdo_sqlite/tests/bug_34630.phpt] (warn:xfail section but test passes)
重新編譯第一次:按照php的paq所說,安裝php時不指定gd安裝路徑。
configure通過,make無法通過:
collect2: ld returned 1 exit status
make: *** [sapi/cli/php] error 1
重新編譯第二次:編譯時指定gd路徑,對gd庫的其它選項使用 --with-jpeg-dir=/usr/local --with-zlib-dir --with-png-dir=/usr/local --with-freetype-dir=/usr/local --with-gd=/usr/local/gd。
configure通過,make通過,make test時解決了前三個問題,只出現sqlite2 pdo和sqlite pdo的錯誤
重新編譯第三次:因為phpmyadmin提示「無法載入mcrypt擴充套件,請檢查您的php配置,所以重新編譯php,加入--with-mcrypt選項,結果在編譯php時遇到了不少問題。
1、configure: error: libjpeg.(also) not found.
2、configure: error: libpng.(also) not found.
解決:yum install libjpeg-devel
yum install libpng-devel
3、error: freetype.h not found.
解決:缺少freetype-devel,yum install freetype-devel
4、遇到configure: error: mcrypt.h not found. please reinstall libmcrypt.而libcrypt已經安裝,在網上查了一下資料,發現是缺少libmcrypt-devel。
解決:yum install libmcrypt-devel
重新編譯第四次:遇到:
/usr/bin/ld: cannot find -lltdl
collect2: ld returned 1 exit status
make: *** [libphp5.la] error 1
解決:錯誤原因是缺少libltdl。
yum install libtool-ltdl libtool-ltdl-devel
最終編譯時指定了以下引數,禁用sqlite2 pdo和sqlite pdo,問題全部解決:
./configure --prefix=/usr/local/php5 --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql=/usr/share/mysql --with-jpeg-dir=/usr --with-png-dir=/usr --with-freetype-dir=/usr --with-gd --enable-exif --enable-mbstring --enable-soap --with-mcrypt --with-curl =/usr/local/curl --with-libxml-dir=/usr/local/libxml2 /bin/xml2-config --without-pdo-sqlite --without-sqlite
CentOS5安裝手記
基本安裝過程和其他linux安裝基本相同,記得在定製軟體時,選上xvsf即可 1.安裝jdk 注意修改系統預設的jdk,參考 http blog.csdn.net hbcui1984 archive 2007 01 08 1477416.aspx 2.安裝myeclipse,如果出錯,參考 http...
硬碟安裝CentOS5
背景 xp 系統,硬碟是c d e f 想在f 裝centos centos 4.92 i386 bin 1of6.iso,centos 4.92 i386 bin 2of6.iso,centos 4.92 i386 bin 6of6.iso 放到c 共 個iso 放到c 其實放到哪個盤你可以自己決...
硬碟安裝CentOS5
背景 xp 系統,硬碟是c d e f 想在f 裝centos centos 4.92 i386 bin 1of6.iso,centos 4.92 i386 bin 2of6.iso,centos 4.92 i386 bin 6of6.iso 放到c 共 個iso 放到c 其實放到哪個盤你可以自己決...