PHP編譯遇到的問題

來源:互聯網
上載者:User

標籤:php   lnmp   

編譯php的時候遇到的問題:


編譯代碼:

./configure --prefix=/server/php-5.4-nginx --with-config-file-path=/server/php-5.4-nginx --with-mysql=/server/mysql-5.5/ --with-mysqli=/server/mysql-5.5/bin/mysql_config --with-iconv-dir --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib --with-libxml-dir=/usr --enable-xml --disable-rpath --enable-safe-mode --enable-bcmath --enable-shmop --enable-sysvsem --enable-inline-optimization --with-curl --with-curlwrappers --enable-mbregex --enable-fpm --enable-mbstring  --with-gd --enable-gd-native-ttf --with-openssl --with-mhash --enable-pcntl --enable-sockets  --with-xmlrpc --enable-zip --enable-soap  --with-mcrypt=/usr/local/

報錯資訊:configure: error: Please reinstall the libcurl distribution -

    easy.h should be in <curl-dir>/include/curl/


解決辦法:yum install curl-devel



再次編譯報錯:

configure: error: jpeglib.h not found.

解決方案:

檢查之後發現已經安裝了libjpeg

[[email protected] php-5.2.14]# yum list installed|grep libpng
libpng.x86_64           2:1.2.49-1.el6_2

或者:

[[email protected] php-5.2.14]# rpm -qa|grep libjpeg
libjpeg-turbo-1.2.1-3.el6_5.x86_64

如果沒有安裝則需要:

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

若是64位系統
解決方案:
yum install libjpeg.x86_64 libpng.x86_64 freetype.x86_64 libjpeg-devel.x86_64 libpng-devel.x86_64 freetype-devel.x86_64 -y

安裝完後再安裝libjpeg-devel

安裝libjpeg-devel

yum -y install libjpeg-devel

記住一點就好了:編譯過程中出現錯誤不可怕,出現一個解決一個就好了。



本文出自 “辛舒展” 部落格,請務必保留此出處http://xinsz08.blog.51cto.com/10565212/1795763

PHP編譯遇到的問題

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.