PHP编译遇到的问题

编译php的时候遇到的问题:php


编译代码:mysql

./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/nginx

报错信息:configure: error: Please reinstall the libcurl distribution -sql

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


解决办法:yum install curl-develcurl



再次编译报错:socket

configure: error: jpeglib.h not found.ide

解决方法:
url

检查以后发现已经安装了libjpegserver

[root@localhost php-5.2.14]# yum list installed|grep libpng
libpng.x86_64           2:1.2.49-1.el6_2

或者:

[root@localhost 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

记住一点就行了:编译过程当中出现错误不可怕,出现一个解决一个就行了。

相关文章
相关标签/搜索