Page 1 of 1

Absolute beginner help with install of imagick using pecl

Posted: 2007-09-01T09:10:07-07:00
by TPM
I have searched high and low for an answer , but I am having no end of problems installing the PHP extension for imagick any help greatly apprcieated. here is a log of the failures:-


Directory of C:\Documents and Settings\TPM\My Documents\kits\php-5.1.6-W
in32\ext\imagick

01/09/2007 14:03 <DIR> .
01/09/2007 14:03 <DIR> ..
15/08/2007 18:00 3,370 config.m4
15/08/2007 18:00 2,149 config.w32
15/08/2007 18:00 39 CREDITS
01/09/2007 14:03 <DIR> examples
15/08/2007 18:00 495,780 imagick.c
15/08/2007 18:00 843 INSTALL
15/08/2007 18:00 3,348 package.xml
15/08/2007 18:00 3,041 php_imagick.h
15/08/2007 18:00 217 TODO
8 File(s) 508,787 bytes
3 Dir(s) 184,811,401,216 bytes free

C:\Documents and Settings\TPM\My Documents\kits\php-5.1.6-Win32\ext\imagi
ck>type install
Linux install

Installing with `pecl` command-line utility

1. Install ImageMagick libraries (at least version 6.2.4)
2. Execute command "pecl install imagick"
3. Make sure you have extension=imagick.so in your php.ini


Installing from sources

1. Install ImageMagick libraries (at least version 6.2.4)
2. Unpack imagick source package
3. Go to imagick folder and type "phpize && ./configure && make
&& make install"
4. Make sure you have extension=imagick.so in your php.ini


Compiling Imagick into PHP

1. Install ImageMagick libraries (at least version 6.2.4)
2. Unpack imagick source package to $PHP_SOURCE_DIR/ext/imagick
3. In php source root directory run commands: "rm configure && .
/buildconf --force"
4. Configure PHP with command "./configure --with-imagick"
5. Run make && make install

Windows install
C:\Documents and Settings\TPM\My Documents\kits\php-5.1.6-Win32\ext\imagi
ck>pecl install imagick
Failed to download pecl/imagick within preferred state "stable", latest release
is version 2.0.0RC1, stability "beta", use "channel://pecl.php.net/imagick-2.0.0
RC1" to install
Cannot initialize 'imagick', invalid or missing package file
Package "imagick" is not valid
install failed

C:\Documents and Settings\TPM\My Documents\kits\php-5.1.6-Win32\ext\imagi
ck>pecl channel://pecl.php.net/imagick-2.0.0RC1 imagick
Command 'channel://pecl.php.net/imagick-2.0.0RC1' is not valid, try 'pear help'

C:\Documents and Settings\TPM\My Documents\kits\php-5.1.6-Win32\ext\imagi
ck>pecl install channel://pecl.php.net/imagick-2.0.0RC1 imagick
Failed to download pecl/imagick within preferred state "stable", latest release
is version 2.0.0RC1, stability "beta", use "channel://pecl.php.net/imagick-2.0.0
RC1" to install
Cannot initialize 'imagick', invalid or missing package file
downloading imagick-2.0.0RC1.tgz ...
Starting to download imagick-2.0.0RC1.tgz (66,972 bytes)
.................done: 66,972 bytes
Package "imagick" is not valid
4 source files, building
ERROR: The DSP imagick.dsp does not exist.

Re: Absolute beginner help with install of imagick using pecl

Posted: 2007-09-01T11:38:26-07:00
by mkoppanen
http://snaps.php.net -> pecl-5.2-dev (zip)

Unpack, copy php_imagick.dll to your extension_dir, add extension=php_imagick.dll to your php.ini, restart webserver and youre good to go.

Re: Absolute beginner help with install of imagick using pecl

Posted: 2007-09-02T03:14:30-07:00
by TPM
thanks,

I copied the DLL into the extension_dir directiry, and modified the php.ini file

but I get the following error:-

[02-Sep-2007 11:04:14] PHP Warning: PHP Startup: Unable to load dynamic library 'c:\php\extensions\php_imagick.dll' - The specified procedure could not be found.

I temprarily tried enabling the load of another dll from the same directory (php_mysql.dll) and this is picked up so I know that apache is seing the directory - I also added php_imagick.dll to system32 directory as well, and the extesion_dir loacation to Path enviroenment variable so I am running out of ideas....

Re: Absolute beginner help with install of imagick using pecl

Posted: 2007-09-02T05:13:22-07:00
by mkoppanen
Which version of PHP you're running ?

Re: Absolute beginner help with install of imagick using pecl

Posted: 2007-09-04T15:29:45-07:00
by TPM
Mikko,

Sorry to take so long coming back, and I do appreciate your help - theres just so much to do......

PHP Version is 5.2.3

not sure if relevant but PHP was installed under C:/Program files/PHP rather than the default location of C:/PHP

I created c:\php\extensions to place place DLL's to load from

Thanks

Roy

Re: Absolute beginner help with install of imagick using pecl

Posted: 2007-09-04T21:23:07-07:00
by mkoppanen
Just to be sure that you have the right version of php_imagick.dll:

What is the size of php_imagick.dll file?

Re: Absolute beginner help with install of imagick using pecl

Posted: 2007-09-04T23:52:28-07:00
by TPM
60.0 KB (61,510 bytes) ,


Thanks

Re: Absolute beginner help with install of imagick using pecl

Posted: 2007-09-05T00:04:44-07:00
by mkoppanen
pecl-5.2-dev (zip) ---> php_imagick.dll is about 4.0MB.

Are you sure you loaded the correct package?

Re: Absolute beginner help with install of imagick using pecl

Posted: 2007-09-05T00:20:57-07:00
by TPM
Exactly the problem - thanks so much.

It is bizare I know I did cut from the ZIP archive and paste to the file location I even got a confirmation warning message to confirm file replacement - I will reproduce the step I took to see if it was me or if there is some underlying mechanism.

to fix I had to delete the incorrerect DLL and then paste in the new file I wonde if this was due to a file locking due to Apache being running.

Anyway thanks again

Roy

Re: Absolute beginner help with install of imagick using pecl

Posted: 2007-11-24T19:34:16-07:00
by fc_dot_army
>> pecl-5.2-dev (zip) ---> php_imagick.dll is about 4.0MB.

>> Are you sure you loaded the correct package?

Where are you finding that? Every php_imagick.dll file I can find for PHP 5.2.1 is around 60kB.

EDIT: Aw nuts. Never mind. Got it.

Re: Absolute beginner help with install of imagick using pecl

Posted: 2007-11-24T20:04:27-07:00
by fc_dot_army
Okay, I have the correct PHP extension but am still getting nowhere.
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\WebServer\\PHP\\ext\\php_imagick.dll' - The specified procedure could not be found.\r\n in Unknown on line 0
I've tried this with both ImageMagick-6.3.7-1-Q16-windows-dll.exe and ImageMagick-6.3.7-1-Q16-windows-static.exe.The dll version fails the prescribed post-installation command line tests. The static version works from the command line, but that's not getting me where I want to go.

Re: Absolute beginner help with install of imagick using pecl

Posted: 2007-11-27T03:06:05-07:00
by mkoppanen
If the extension works from command line then it should work with apache also. Are you sure you run php5 with your apache?