Pro-Test Install PHP
1. Tar zvxf php-5.3.8.tar.gz
2. CD php-5.3.8
3.
./configure \
--prefix=/usr/local/php \
--with-mysql=/usr/local/mysql \
--WITH-APXS=/USR/LOCAL/APACHE2/BIN/APXS \
--with-libxml-dir=/usr/local/libxml2
A problem occurred:
Configure:error:xml2-config not found. Please check your
LIBXML2 installation.
[Email protected] php-5.3.28]#--prefix=/usr/local/php \
-------------------------------------------------------
Solution:
Check if the LIBXM package is installed
[Email protected] php-5.3.8]# Rpm-qa |grep libxml2
libxml2-2.6.26-2.1.12
libxml2-python-2.6.26-2.1.12
Reinstall the LIBXML2 and Libxml2-devel packages
Yum Install LIBXML2
Yum Install Libxml2-devel-y
Find out if the Xml2-config file exists after installation
[[email protected] php-5.3.8]# Find/-name "Xml2-config"
/usr/bin/xml2-config
Reinstall PHP if it exists
[Email protected] php-5.3.8]#./configure
The sign of successful installation is the presence of a license
--------------------------------------------------
And then re-
4.
Make && make install
Method Two: Install LIBXML2 (not tested)
1 tar zxvf libxml2-2.6.32.tar.gz
2 CD libxml2-2.6.32
3./configure--PREFIX=/USR/LOCAL/LIBXML2
4 Make
5 Make Install