Because gd2 supports the creation of true color images, You need to upgrade the server. If your machine is originally installed with PHP or apache rpm or a lower version. you can delete it now. It is simpler to delete and install it. However, my actual operation is to delete the kerosene and install it directly. of course you can be the same as me!
First, you must have GCC on the server. Otherwise, you cannot do anything. You can use gcc-v to check whether GCC is installed,
# Gcc-v
Readingspecs from/usr/lib/gcc-lib/i386-redhat-linux/3.2.3/specs
Configured :.. /configure -- prefix =/usr -- mandir =/usr/share/man -- infodir =/usr/share/info -- enable-shared -- enable-threads = posix -- disable-checking -- with-system-zlib -- enable-_ cxa_atexit -- host = i386-redhat-linux
Thread model: posix
Gcc version 3.2.3 20030502 (Red Hat Linux 3.2.3-34)
The above similar information indicates that GCC already exists,
If you don't have it, install it now. As for how to install it, I won't talk about it. You can install it on a CD or download the source file. Of course, your version is not necessarily 3.2.3!
Download all of the following:
Httpd-2.0.X.tar.gz version is best to download the latest,: http://www.apache.org
MySQL-client-4.0.20-0.i386.rpm
MySQL-server-4.0.20-0.i386.rpm (if you want to upgrade mysql Please download,: http: // www.mysql.org is of course also download the latest version of the best, because I do not intend to install mysql, it will be omitted, install mysql first !)
Php-5.0.X.tar.gz: http://www.php.net
ZendOptimizer-2.5.3-linux-glibc21-i386.tar.gz
The latest version of zend seems to be a problem. You can download this version. zend is used to accelerate php. You can choose not to install it! : Http: // www.zend.com
Gd-2.0.28.tar.gz of this software, php recommended is: http://www.boutell.com/gd/ but for some reason, developers do not support the creation of gif images, this is not very convenient, So, I downloaded a support for gif images, that is, http: // www.rime.com. au/gd/
Libxml2-2.X.X.tar.gz:
Zlib-1.X.X.tar.gz forgot, find it yourself
Jpegsrc.v6b.tar.gz: ftp://ftp.uu.net/graphics/jpeg/
Libpng-1.2.5.tar.gz: http://www.libpng.org/pub/png/libpng.html
Freetype2-X.X.tar.gz: http://www.fretype.org
Xpm-3.4k-2.i386.rpm forgot, find it yourself
The above are the official addresses I downloaded. X in the software version, you can see which version you want to use, but it is best to use the latest stable version! If you have installed other versions of the above software before, you can choose not to install it!
Install the MYSQL server:
# Rpm-ivh MySQL-server-4.0.20-0.i386.rpm
# Rpm-ivh MySQL-client-4.0.20-0.i386.rpm
Try again after installation
# For mysql, if the password is set, the test method is (mysql-u root-proot-h localhost note that there is no space in the-p post-coal and the password is directly followed)
Welcome to the MySQL monitor. Commands end with; or \ g.
Your MySQL connection id is 27651 to server version: 4.0.20-standard
Type 'help; 'or' \ H' for help. Type '\ C' to clear the buffer.
That's all!
Please change the mysql password by yourself!
Install XPM
# Rpm-ivhxpm-3.4k-2.i386.rpm
Install libxml
# Tar-zxf libxml2-2.6.16.tar.gz
# Cd libxml2-2.6.16
#./Configure (xml can be installed by default, do not specify the path, because php may not find it during installation, PHP5 only supports libxml2-2.5.10 and later versions)
# Make
# Make install
Install zlib
# Tar-zxf zlib-1.2.2.tar.gz
# Cd zlib-1.2
#./Configure -- prefix =/usr/local/zlib2! Similar to the following !)
# Make
# Make install
Install jpeg
# Tar-zxf restart src.v6b.tar.gz
# Cd jpeg-6b/
#./Configure -- prefix =/usr/local/Issue 6
# Make
# Make install-lib
If you choose to install it by default, it may be very smooth. After specifying the path, please first create the following folder
Error message:.../usr/bin/install-c-m 644 jconfig. h/usr/local/Issue 6/include/jconfig. h
/Usr/bin/install: The general file '/usr/local/defaults 6/include/jconfig. H' cannot be created: the file or directory does not exist.
Make: *** [install-headers] Error 1
# Mkdir/usr/local/limit 6
# Mkdir/usr/local/latest 6/include
# Mkdir/usr/local/IPv6/lib
# Make install-lib
# Make install
If an error occurs during installation:
/Usr/bin/install: The general file '/usr/local/defaults 6/lib/libjpeg. A' cannot be created: the file or directory does not exist.
Make: *** [install-lib] Error 1
Create the following folder:
# Mkdir/usr/local/IPv6/lib
# Make install
/Usr/bin/install-c cjpeg/usr/local/Listen 6/bin/cjpeg
/Usr/bin/install: The general file '/usr/local/defaults 6/bin/cjpeg' cannot be created: the file or directory does not exist.
Make: *** [install] Error 1
# Mkdir/usr/local/partition 6/bin
/Usr/bin/install-c-m 644./c0000.1/usr/local/sort 6/man/man1/c0000.1
/Usr/bin/install: The general file '/usr/local/Hangzhou 6/man/man1/c0000.1' cannot be created: the file or directory does not exist.
Make: *** [install] Error 1
# Mkdir/usr/local/IPv6/man
# Mkdir/usr/local/IPv6/man/man1
# Make install
Okay, until the installation is successful!