Page 1 of 1

Problem with magickwand installation in linux server

Posted: 2007-09-21T00:39:20-07:00
by vinodkalpaka
We installed ImageMagick..latest version (ImageMagick 6.3.5-9 and MagickWand 1.0.5) in the linux server and tried to install MagickWandFor PHP but showed Configure Error : You need at least PHP version 5.1.3 to use Imagick.

Current versions in the server:
php: 4.3.11
MagickWand Extension Version : 1.0.4
ImageMagick version : ImageMagick 6.3.5 08/17/07 Q16

Is it necessary to install the version 5.1.3 ?

Re: Problem with magickwand installation in linux server

Posted: 2007-09-21T06:51:38-07:00
by magick
Try removing that restriction from the config.m4 configuration file and rerun phpize. See if it complains. The original author of MagickWand for PHP put the PHP version restriction in the script but we're not sure why.

Re: Problem with magickwand installation in linux server

Posted: 2007-09-21T10:15:38-07:00
by mkoppanen
vinodkalpaka wrote:You need at least PHP version 5.1.3 to use Imagick.
My understanding is that MagickWand does not require PHP5. In Imagick we have this check because zend_std_object_init is not present before 5.1.3. I noticed that this check is still present in MagickWand beta 1.0.6.

Re: Problem with magickwand installation in linux server

Posted: 2007-09-22T01:41:45-07:00
by vinodkalpaka
which are the lines in config.m4 to remove.

Here are the last lines of the above file which contains infomation regarding php version.

Code: Select all

[i]AC_MSG_CHECKING(if PHP version is at least 5.1.3)

		tmp_version=$PHP_VERSION
		if test -z "$tmp_version"; then
  		if test -z "$PHP_CONFIG"; then
    			AC_MSG_ERROR([php-config not found])
  		fi
   			MAGICKWAND_PHP_VERSION_ORIG=`$PHP_CONFIG --version`;
		else
			MAGICKWAND_PHP_VERSION_ORIG=$tmp_version
		fi

		if test -z $MAGICKWAND_PHP_VERSION_ORIG; then
			AC_MSG_ERROR([failed to detect PHP version, please report])
		fi

		MAGICKWAND_PHP_VERSION_MASK=`echo ${MAGICKWAND_PHP_VERSION_ORIG} | awk 'BEGIN { FS = "."; } { printf "%d", ($1 * 1000 + $2) * 1000 + $3;}'`

		if test $MAGICKWAND_PHP_VERSION_MASK -ge 5001003; then
				AC_MSG_RESULT(found version $MAGICKWAND_PHP_VERSION_ORIG)
		else
				AC_MSG_ERROR(no. You need at least PHP version 5.1.3 to use Imagick.)
		fi

		AC_DEFINE(HAVE_MAGICKWAND,1,[ ])[/i]

Re: Problem with magickwand installation in linux server

Posted: 2007-09-22T03:03:47-07:00
by mkoppanen
These lines should do it:


AC_MSG_CHECKING(if PHP version is at least 5.1.3)

tmp_version=$PHP_VERSION
if test -z "$tmp_version"; then
if test -z "$PHP_CONFIG"; then
AC_MSG_ERROR([php-config not found])
fi
MAGICKWAND_PHP_VERSION_ORIG=`$PHP_CONFIG --version`;
else
MAGICKWAND_PHP_VERSION_ORIG=$tmp_version
fi

if test -z $MAGICKWAND_PHP_VERSION_ORIG; then
AC_MSG_ERROR([failed to detect PHP version, please report])
fi

MAGICKWAND_PHP_VERSION_MASK=`echo ${MAGICKWAND_PHP_VERSION_ORIG} | awk 'BEGIN { FS = "."; } { printf "%d", ($1 * 1000 + $2) * 1000 + $3;}'`

if test $MAGICKWAND_PHP_VERSION_MASK -ge 5001003; then
AC_MSG_RESULT(found version $MAGICKWAND_PHP_VERSION_ORIG)
else
AC_MSG_ERROR(no. You need at least PHP version 5.1.3 to use Imagick.)
fi
If that does not help just remove these two lines:

AC_MSG_ERROR([failed to detect PHP version, please report])
AC_MSG_ERROR(no. You need at least PHP version 5.1.3 to use Imagick.)

Re: Problem with magickwand installation in linux server

Posted: 2007-09-22T03:24:16-07:00
by vinodkalpaka
Thank you all. I have removed the lines related to the php version and now it is working.