Restoring GD into OSX 10.5 Server’s Apache/PHP set up
Posted: October 12th, 2009 | Author: Foamcow | Filed under: General | | No Comments »
This keeps happening!
I don’t know if it’s because at some point I’ve hacked the default set up of Apache on our Xserve or something else but every time Apple does a PHP/Apache update it stuffs up the asset management tool we run.
The problem is that the default Apache set up doesn’t have the GD library installed. It’s no great shakes to install this but getting it to actually load is a pig.
For reference, it seems that Apache (our version at least) is running in 64bit mode (it’s on 64bit hardware so great) but GD won’t work in 64bit mode. The trick, therefore is to make Apache run in 32bit mode and you do it like so:
sudo mv /usr/sbin/httpd /usr/sbin/httpd.ub sudo lipo -thin ppc7400 /usr/sbin/httpd.ub -output /usr/sbin/httpd.ppc7400 sudo ln -s /usr/sbin/httpd.ppc7400 /usr/sbin/httpd
I’m wondering if there is some means to make it ALL 64bit and so avoid the problem in future.