PHP make安装似乎突然结束,不更新libphp5.so

我试图编译PHP 5.3.3,在经历了很多起伏之后,我终于做了“make”,然后是“make install”,它显示了这一点:

root@server [/tmp/php-5.3.3]# make install Installing PHP SAPI module: cgi Installing PHP CGI binary: /usr/bin/ Installing PHP CLI binary: /usr/bin/ Installing PHP CLI man page: /usr/share/man/man1/ Installing shared extensions: /usr/lib64/20090626/ Installing build environment: /usr/lib64/build/ Installing header files: /usr/include/php/ Installing helper programs: /usr/bin/ program: phpize program: php-config Installing man pages: /usr/share/man/man1/ page: phpize.1 page: php-config.1 /tmp/php-5.3.3/build/shtool install -c ext/phar/phar.phar /usr/bin ln -s -f /usr/bin/phar.phar /usr/bin/phar Installing PDO headers: /usr/include/php/ext/pdo/ 

它看起来不像它完成,因为/usr/lib64/httpd/modules/libphp5.so仍然显示一个旧的date:

 -rwxr-xr-x 1 root root 3193768 Mar 31 2010 libphp5.so 

你需要build立apache2handler:

 $./configure --with-apxs2 

然后清理生成目录并build立php:

 $make clean $make $make install 

阅读: http : //www.php.net/manual/en/install.unix.apache2.php

在php的./configure中可能你select了一个前缀,但这不是必须的,你可以用./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql来编译./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql

当然,它并没有更新mod_php。 你告诉它build立cgi代替。