Php imagemagick

So I just got off a live chat with DH support trying to set up the imagemagick extension for php.

We got as far as setting me up a CGI-bin directory with a custom php.ini

but now support says I’m on my own for compiling autoconf, imagemagick and magickwand to get the file working.

Has anyone done this successfully?