PHP 4.3 Upgrade for Image Libraries
I am trying to resize an image in PHP and got the following:
Warning: imagecreatetruecolor(): requires GD 2.0 or later in /var/www/html/include/imageFunctions.php on line 19
Warning: imagecopyresampled(): requires GD 2.0 or later in /var/www/html/include/imageFunctions.php on line 22
So, I followed the directions for installing GD 2.0
Make sure you have libjpeg and libpng installed
1. Grab GD-2.0.1.
2. tar zxvf gd-2.0.1.tar.gz
3. cd gd-2.0.1
4. Edit the Makefile and change the LIBS line to be:
LIBS=libgd.a -lpng -lz -ljpeg -lfreetype -lm
5. make libgd.a (don't need to do a make install)
6. Now build PHP using these flags:
--with-gd=/home/<you>/gd-2.0.1
--with-freetype-dir=/usr
--enable-gd-native-ttf (for PHP 4.0.6 leave off trailing 'f')
--enable-gd-imgstrttf
--with-jpeg-dir=/usr
--with-png-dir=/usr
--with-zlib
Now, I am on the last step 6 above. Where do I go to compile PHP on a standard RedHat 9 install? If I download PHP 4.3 from the PHP site, what happens to all of these:
php-ldap-4.2.2-17
php-mysql-4.2.2-17
php-4.2.2-17
php-manual-4.2.2-17
php-devel-4.2.2-17
php-pgsql-4.2.2-17
php-odbc-4.2.2-17
php-snmp-4.2.2-17
php-imap-4.2.2-17
I am using mysql. So, do I have to do something to all of the above or will they come with the 4.3 PHP?
Thanks
|