重新编译php需要以下软件包:
apache apache-devel
postgresql postgresql-devel
MySQL-devel
2、重新配置、编译和安装php3
安装php3源代码包:
rpm -i php-3.0.12-6.src.rpm
它将php源代码安装在/usr/src/redhat目录下,进入该目录,按下面的命令进行配置和编译:
cd /usr/src/redhat/SPECS
vi php.spec
编辑php.spec文件,找到%build小节,在关于./configure的选项部分加入:
--with-mysql=/usr \
选项,它指出php支持MySQL数据库。
%build cd imap-4.5 make RPM_OPT_FLAGS="$RPM_OPT_FLAGS" lnp cd .. autoconf CFLAGS="-fPIC" ./configure --prefix=/usr --with-apxs=/usr/sbin/apxs --with-config-file-path=/etc/httpd --enable-safe-mode --with-exec-dir=/usr/bin --with-system-regex --disable-debug --with-zlib --enable-debugger --enable-magic-quotes --with-mysql=/usr --enable-track-vars
保存修改,重建rpm包:
rpm -bb /usr/src/redhat/SPECS/php.spec
最后,在/usr/src/redhat/RPMS/i386目录下可以找到相应的二进制rpm包,重新安装它们:
rpm -i /usr/src/redhat/RPMS/i386/*
3、配置httpd.conf和srm.conf
| 对此文章发表了评论 |
