分类: 系统运维
2010-09-29 15:54:11
# rpm -qa | grep zlib
# rpm -qa | grep libpng
# rpm -qa | grep freetype
# rpm -qa | grep jpeg
# rpm -qa | grep gd
(1) 安装zlib
# tar zxvf zlib-1.2.2.tar.gz
# cd zlib-1.2.2
# ./configure
# make
# make install
(2) 安装libpng
# tar zxvf libpng-1.2.7.tar.tar
# cd libpng-1.2.7
# cd scripts/
# mv makefile.linux ../makefile
# cd ..
# make
# make install
注意,这里的makefile不是用./configure生成,而是直接从scripts/里复制一个。
(3) 安装freetype
# tar zxvf freetype-2.1.9.tar.gz
# cd freetype-2.1.9
# ./configure
# make
# make install
(4) 安装Jpeg
# tar zxvf jpegsrc.v6b.tar.gz
# cd jpeg-6b/
# ./configure --enable-shared
# make
# make test
# make install
注意:这里configure一定要带--enable-shared参数,不然,不会生成共享库
(5)安装GD
# tar zxvf gd-2.0.33.tar.gz
# cd gd-2.0.33
# ./configure --with-png --with-freetype --with-jpeg
# make install
# rpm -qa | grep mysql
# rpm -e MySQL-xxxxxx
# rpm -ivh MySQL-client-4.0.26-0.i386.rpm
# rpm -ivh MySQL-server-4.0.26-0.i386.rpm
# /etc/rc.d/init.d/mysql start
# mysqladmin -u root password new_password_for_root
# tar xzvf httpd-2.0.55.tar.gz
# cd httpd-2.0.55
# ./configure --prefix=/usr/local/apache --enable-so (这里为了节省内存提高Apache性能只允许了加载动态模块参数,而没有加载其他的模块。
如果需要什么模块,今后手动挂载上去就可以了。)
# make
# make install
# vi /usr/local/apache/conf/httpd.conf
# tar xzvf php-4.4.1.tar.gz
# cd php-4.4.1
# ./configure --prefix=/usr/local/php --with-apxs2=/usr/local/apache/bin/apxs --with-mysql --with-config-file-path=/usr/local/php/etc --with-gd --enable-gd-native-ttf --enable-gd-jis-conv --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib --enable-xml --enable-mbstring
# make
# make install
# cp php.ini-recommend /usr/local/php/etc/php.ini
# vi /usr/local/apache/conf/httpd.conf
# tar xzvf Zend*.gz
# rm -f Zend*.gz
# cd Zend*
# ./install.sh
# tar xzvf phpMyAdmin-2.7.0-pl1.tar.gz
将解压后的目录移动到服务器网站的根目录中(架设网站根目录为/var/www)
# mv phpMyAdmin-2.7.0-pl1 /var/www/phpMyAdmin
# cd /var/www/phpMyAdmin
# vi config.inc.php