編譯php時遇到的錯誤

error 1

checking for xml2-config path...
configure: error: xml2-config not found. Please check your libxml2 installation.

lib庫沒裝  先用 yum search 名字 看是否能搜到名字 ,找到名字後 把軟件包 開發包裝上

解決辦法

yum install libxml2-devel.x86_64

error 2

checking for pkg-config... /usr/bin/pkg-config
configure: error: Cannot find OpenSSL's <evp.h>

ssl沒裝

解決辦法

 yum  install  openssl.x86_64 openssl-devel.x86_64 -y

error 3

checking for BZip2 in default path... not found
configure: error: Please reinstall the BZip2 distribution

bzip2軟件包沒有安裝

解決辦法

yum install bzip2-devel.x86_64 -y

error 4

configure: error: Please reinstall the libcurl distribution -
    easy.h should be in <curl-dir>/include/curl/

curl和curl庫文件沒有安裝

解決辦法

yum install libcurl.x86_64 libcurl-devel.x86_64 -y

error 5

checking whether to enable JIS-mapped Japanese font support in GD... no
checking for fabsf... yes
checking for floorf... yes
configure: error: jpeglib.h not found

GD庫沒有安裝

解決辦法

yum install libjpeg.x86_64 libpng.x86_64 freetype.x86_64 libjpeg-devel.x86_64 libpng-devel.x86_64 freetype-devel.x86_64 -y

error 6

checking for stdarg.h... (cached) yes
checking for mcrypt support... yes
configure: error: mcrypt.h not found. Please reinstall libmcrypt.

libmcrypt庫沒有安裝 ,要是不能用yum安裝的話  就要去下載個gz包 自己編譯安裝

(編譯安裝  ./configure --piefix=/usr/local/libmcrypt   make && make install)

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
error7
要是錯誤裏面含有mysql的  那是mysql-devel 沒有安裝
configure: error: Cannot find ldap libraries in /usr/lib

解決辦法:

cp -frp /usr/lib64/libldap* /usr/lib/
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章