As I promised, this my second explanation about how to build a PHP web development environment in OS X (10.5).
As I mentioned a very basic configuration ships with the distro by default. But for me it was not enough. Going further from my last setup (http://itarato.blogspot.com/2009/06/first-macbook-webdeveloper-enviroment.html) I noticed there isn't APC for PHP. No GD2 support (neither GD1). I depressed till found this miracle: http://www.entropy.ch/software/macosx/php/
Marc Liyanage compiled a very good PHP 5.2.9 with a lot of modules. If you step through his description you can install it quite easily. At the end you get a new php.ini. You need to add your previous xdebug settings to it. For APC see this article: http://discussions.apple.com/thread.jspa?threadID=1578979. As it turned out, the pecl related APC is wrong on OS X, but the original APC compilation will work.
Lately my favorite high end IDE is the stable NetBeans (6.7 RC3 has a StackOverflow for me). For PHP it works out of the box but for any Java related project I had to change the default java classpath: http://statistics.netbeans.org/analytics/detail.do?id=150231
In a nutshell thats all about it. The MySQL and Apache server works as I wrote before. By the way just for play I tried the free MAMP application, but I found it a little bit old for my claims. It has a pretty cool minimalistoc control interface, works fine but doesn't contain some imprtant module. To be honest I was't bother with it so much. (My bad.)
One thing. Last week I began to use NetBeans for debugging PHP projects. The reason I didn't use it for debug I didn't know how I can examine pages other than index.php. But as a matter of fact if it starts and finish it's first debug run you can enter any subpage into the browser (the same has the xdebug session) and the debug cycle will start again. So its really cool. There is a big advantage against ViM+XDebug, I like more NetBeans's variable browser. In ViM you are restricted to the php xdebug config (ex maximum variable nested level) and the limited height of the editor. But sake of NB's tree visualizaton you can traverse arrays and objects quite convenient.
(Other tiny minus sign for osx - the default key bindings messes the F2..F6 key usages in vim.)
Thats it. Any webdev environment related question would be welcomed:)