• PHP编译安装之常见问题


      正式服的PHP环境,一般都会进行编译安装,汇总一下经常遇到的一些问题

    1.Call to undefined function crmebutilsimagecreate

    解决:需要安装gd库

    1)进入到源码包ext目录下的gd下
    2) phpize(提示如果找不到, 则需要安装autoconf   yum install -y autoconf)
    3)   ./configure --with-php-config=/usr/local/php7/bin/php-config --with-gd
    4)   make && make install
    5)   php.ini 文件中添加 extensions=gd.so

    2.Call to undefined function crmebutilsimagettftext

    解决:需要安装freetype

    1)wget wget http://download.savannah.gnu.org/releases/freetype/freetype-2.4.0.tar.bz2
    2) tar -jxf freetype-2.4.0.tar.bz2
    3)cd freetype-2.4.0
    4)./configure --prefix=/usr/local/freetype
    5) make && make install
    6) 来到gd源码包的目录下,重新编译  phpize
    7)./configure --with-php-config=/usr/local/php7/bin/php-config --with-freetype-dir=/usr/local/freetype/
    8)make  && make install  
    9)重启php-fpm  /etc/init.d/php-fpm restart 

  • 相关阅读:
    cogs 908 校园网
    植保___农药基础知识
    底层终端-.c文件之间的调用
    指针复习
    电子工程世界
    电机与维修
    航拍部分
    系统集成与维修
    关于大型架构数据库和web一步一步优化草案
    服务器安装git,如何以秘钥方式提交
  • 原文地址:https://www.cnblogs.com/xingxia/p/php_install_problems.html
Copyright © 2020-2023  润新知