EDIT (Dec 19, 2005):
I have written a formal guide on PHP4 on FC4.
As a followup to my previous post about PHP4 on FC4, I decided to abandon PHP5 altogether. I spent some time to try and get the PHP4 src.rpm from FC3 to compile correctly in FC4. As it turned out neither the GCC4 nor the GCC3.2 included in FC4 would compile everything properly. So I decided to try GCC3.4 (which I installed from source long ago when first tweaking with FC4).
Anyways it worked. I have 15 RPM files which I don’t think I will upload unless someone really cares for them. I’ve only done this in the process of seeing if there is an advantage in using my own compiled RPM’s as opposed to using the FC3 RPM’s. Right now I don’t think that there is.
In the end if you force uninstall all PHP5 RPM files in FC4, and then you install the FC3 PHP4 RPM’s, it does work.
[root]# rpm -e php-imap php-ldap php-mysql php-pear php
Install any PHP4 RPM you want from Fedora Core 3 Updates. Make sure to install the
php-pear RPM files together.