PHP

编译php的imagick模块报错

今天编译php的扩展模块imagick,报错如下: [code][root@jweb1 imagick-3.1.2]# ./configure --with-php-config=/usr/local/php5.4.45/bin/php-config --with-imagick=/usr/local/imagemagick checking for grep that handles long lines and -e... /bin/grep checking for egrep... /bin/grep -E checking for a sed that does not truncate output... /bin/sed checking for cc... cc checking for C compiler default output file name... a.out checking whether the C compiler works... yes checking whether we are cross compiling... no checking for suffix of executables... checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether cc accepts -g... yes checking for cc option to accept ISO C89... none needed checking how to run the C preprocessor... cc -E checking for icc... no checking for suncc... no checking whether cc understands -c and -o together... yes checking for system library directory... lib checking if compiler supports -R... no checking if compiler supports -Wl,-rpath,... yes checking build system type... x86_64-unknown-linux-gnu checking host system type... x86_64-unknown-linux-gnu checking target system type... x86_64-unknown-linux-gnu checking for PHP prefix... /usr/local/php5.4.45 checking for PHP includes... -I/usr/local/php5.4.45/include/php -I/usr/local/php5.4.45/include/php/main -I/usr/local/php5.4.45/include/php/TSRM -I/usr/local/php5.4.45/include/php/Zend -I/usr/local/php5.4.45/include/php/ext -I/usr/local/php5.4.45/include/php/ext/date/lib checking for PHP extension directory... /usr/local/php5.4.45/lib/php/extensions/no-debug-non-zts-20100525 checking for PHP installed headers prefix... /usr/local/php5.4.45/include/php checking if debug is enabled... no checking if zts is enabled... no checking for re2c... no configure: WARNING: You will need re2c 0.13.4 or later if you want to regenerate PHP parsers. checking for gawk... gawk checking whether to enable the imagick extension... yes, shared checking whether to enable the imagick GraphicsMagick backend... no checking ImageMagick MagickWand API configuration program... configure: error: not found. Please provide a path to MagickWand-config or Wand-config program.[/code]请问这是什么问题,少什么依赖吗?
已邀请:

空心菜 - 牛逼你来

赞同来自: Ansible

你仔细查看你报错内容,其中:
configure: WARNING: You will need re2c 0.13.4 or later if you want to regenerate PHP parsers.
是因为缺少re2c的依赖。
 
Yum安装如下:
yum -y install re2c
编译安装参考如下:
wget https://sourceforge.net/projects/re2c/files/0.16/re2c-0.16.tar.gz
tar zxf re2c-0.16.tar.gz && cd re2c-0.16
./configure
make && make install


configure: error: not found. Please provide a path to MagickWand-config or Wand-config program是因为缺少ImageMagick的开发包,可以如下安装操作:
yum -y install ImageMagick-devel

要回复问题请先登录注册