Re-compile the lamp environment with reference to lampbrother.
The shell script compiled and compiled here
cd /lamp/libxml2-2.6.30./configure --prefix=/usr/local/libxml2/make make install cd /lamp/libmcrypt-2.5.8./configure --prefix=/usr/local/libmcrypt/make make installcd /lamp/libmcrypt-2.5.8/libltdl./configure --enable-ltdl-installmakemake installcd /lamp/zlib-1.2.3./configuremakemake install cd /lamp/libpng-1.2.31./configure --prefix=/usr/local/libpng/makemake installmkdir /usr/local/jpeg6mkdir /usr/local/jpeg6/binmkdir /usr/local/jpeg6/libmkdir /usr/local/jpeg6/includemkdir -p /usr/local/jpeg6/man/man1cd /lamp/jpeg-6b./configure --prefix=/usr/local/jpeg6/ --enable-shared --enable-staticmakemake installcd /lamp/freetype-2.3.5./configure --prefix=/usr/local/freetype/makemake installcd /lamp/autoconf-2.61./configuremake make install cd /lamp/gd-2.0.35./configure --prefix=/usr/local/gd2/ --with-jpeg=/usr/local/jpeg6/ --with-freetype=/usr/local/freetype/makemake installcd /lamp/httpd-2.2.9./configure --prefix=/usr/local/apache2/ --sysconfdir=/etc/httpd/ --with-included-apr --disable-userdir --enable-so --enable-deflate=shared --enable-expires=shared --enable-rewrite=shared --enable-static-supportmakemake install /usr/local/apache2/bin/apachectl startecho "/usr/local/apache2/bin/apachectl start" >> /etc/rc.d/rc.sysinitcd /lamp/ncurses-5.6./configure --with-shared --without-debug --without-ada --enable-overwritemake make installgroupadd mysqluseradd -g mysql mysqlcd /lamp/mysql-5.0.41./configure --prefix=/usr/local/mysql/ --with-extra-charsets=allmakemake installcp support-files/my-medium.cnf /etc/my.cnf/usr/local/mysql/bin/mysql_install_db --user=mysqlchown -R root /usr/local/mysqlchown -R mysql /usr/local/mysql/varchgrp -R mysql /usr/local/mysql/usr/local/mysql/bin/mysqld_safe --user=mysql &cp /lamp/mysql-5.0.41/support-files/mysql.server /etc/rc.d/init.d/mysqldchown root.root /etc/rc.d/init.d/mysqldchmod 755 /etc/rc.d/init.d/mysqldchkconfig --add mysqldchkconfig --list mysqldchkconfig --levels 245 mysqld off cd /lamp/php-5.2.6./configure --prefix=/usr/local/php/ --with-config-file-path=/usr/local/php/etc/ --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql=/usr/local/mysql/ --with-libxml-dir=/usr/local/libxml2/ --with-jpeg-dir=/usr/local/jpeg6/ --with-freetype-dir=/usr/local/freetype/ --with-gd=/usr/local/gd2/ --with-mcrypt=/usr/local/libmcrypt/ --with-mysqli=/usr/local/mysql/bin/mysql_config --enable-soap --enable-mbstring=all --enable-sockets makemake installcp php.ini-dist /usr/local/php/etc/php.iniecho "Addtype application/x-httpd-php .php .phtml" >> /etc/httpd/httpd.conf/usr/local/apache2/bin/apachectl restart
You can download and compile the Software Based on the software version. (Refer to my http://www.cnblogs.com/yimiao/archive/2012/05/06/2485679.html)
[Others]
To enable other extensions of PHP, such as curl
1. first go to the PHP source code curl directory
CD/usr/local/webdev/tools/php-5.2.6/EXT/curl // usr/local/webdev/PHP/bin/phpize # After executing this statement, the config script will survive. /configure -- prefix =/usr/local/curl/-- With-PHP-Config =/usr/local/webdev/PHP/bin/PHP-config
After the compilation and installation are completed, the yum install curl-devel will be executed if an error occurs in the middle)
/Usr/local/webdev/PHP // lib/PHP/extensions/no-debug-non-zts-20060613/
Directory to generate curl. So
Then modify PHP. ini (extensions_dir = you store the extended directory and add extension = curl. So)