I think you should add a line like --with-imagick in the configure.php file and rebuild php. But then again this is just theory and something tells me you have to download the package here http://pear.php.net/get/imagick and put it somewhere so php includes it during compile. I've only installed it as a perl module not php.
It was just as easy as installing the /usr/ports/graphics/ImageMagick port
ImageMagick is called with exec()
I moved the ImageMagick binaries to /usr/local/bin/imagemagick/ and added this directory to the safe_exec_dir or something like that in php.ini so I can keep safe mode on.