ImageMagic图像处理软件及扩展模块,如何在php配置中添加扩展的模块


1、安装ImageMagic图像软件

    ImageMagic主要精力集中在性能、减少bug以及提供稳定的API和ABI上

    安装方法:

            tar zxf ImageMagick.tar.gz

            cd    ImageMagick-6.5.1-2/

            ./configure

            make

            make    install

    

    注:如果make出错,解决办法:yum    install    -y    perl-CPAN或perl-devel

            报错要注意看提示!


2、安装p_w_picpathick php扩展插件

    安装p_w_picpathick扩展插件,需要先安装ImageMagic图像安装

    安装方法:

    解包软件,进入目录

    执行/usr/local/php/bin/phpize

    ./configure    --with-php-config=/usr/local/php/bin/php-config

    make

    make    install



    在php.ini配置中加入模块

    vim    php.ini

    在配置文件中找到

    ;extension_dir="./"

    修改为

    extension_dir="加入模块路径"

    然后到配置文件结尾加入如下

    extension = memcache.so

    extension = pdo_mysql.so

    extension = imagick.so

    保存,退出

    重启使之生效