Sunday, October 9th, 2005 ~ 12:56 pm by Mauriat Miranda
EDIT (Dec 19, 2005):
I have written a formal guide on PHP4 on FC4.
One of my biggest difficulties with using Fedora Core 4 was that it packages PHP5 with the Apache webserver. Any experienced person should know that Fedora Core is probably a terrible Linux Distribution to be using for a large scale Web Server on the Public Internet. However, it may be sufficient for home or Intranet usage.
What I like to do is, I mirror my public main site mjm wired on my home Linux computer. This was very easy with FC1 - FC3, however PHP5 broke several things in my PHP code. I tried fixing most of them, but it wasn’t worth the effort since my current hosting provider is still on PHP v4.3.10. Anyways, I tried meddling with the PHP4 RPM in FC3 - that was no good. Then I tried recompiling the source RPM for FC3 (src.rpm), but that caused too many compiler errors and with over 60 lines of configure options to compile I couldn’t figure out all the dependancies and flags to satisfy the compile. I had some problems with some XML libraries.
In the end I just compiled the tar.bz2 with some minimal settings. I set the install directory to use
/opt/php4 so as not to disturb PHP5. It properly installs the PHP4 Apache Module in the correct location. Then I had to edit
/etc/httpd/conf.d/php.conf to disable PHP5 and enable PHP4. So now Apache2 on FC4 runs PHP4 correctly for me. I know there is some way to run them in parallel with controlling certain directories and controlling certain Types (.php, .php4, .php5), but I don’t require this at the moment.
I might write a formal process on this later when I get the time. However, I do think that there MUST be a better way to do this, I am open to suggestion or tips.