You know that PHP is installed and ready to go by default on OSX, right? Turn on the webserver in the sharing control panel and you're set. It's installed as a shared object, too, so you can compile a newer / custom version if necessary. Just pick up the configure line from phpinfo(); and use that to configure a custom version from source.