您的位置:首页 > 编程语言 > PHP开发

有关编译安装php和php-fpm时出现的问题

2012-05-24 10:41 405 查看
首先安装的是php5.16版本的,需要另外安装php-fpm,结果安装半天还是有问题。改安装php5.3版本,因为自带了fpm模块,直接编译上去就行了。编译php,./configure--with-iconv-dir=/usr/local/\--with-freetype-dir\--with-jpeg-dir\--with-png-dir\--with-zlib\--with-mhash\--enable-sockets\--enable-ftp\--with-libxml-dir\--enable-xml\--disable-rpath\--enable-safe-mode\--enable-bcmath\--enable-shmop\--enable-sysvsem\--enable-inline-optimization\--with-curl\--with-curlwrappers\--enable-mbregex\--enable-mbstring\--with-mcrypt\--with-gd\--enable-gd-native-ttf\--with-openssl\--with-mhash\--enable-pcntl\--enable-sockets\--with-ldap\--with-ldap-sasl\--enable-fpm\--with-xmlrpc\--enable-zip\--enable-soap\--without-pear结果make的时候就会出现如下错误:libtool: link: `sapi/fpm/fpm/fpm_children.lo' is not a valid libtool object查找了一下,说是libtool版本太低,自己查了一下自己版本,是2005年的版本,于是安装了一个2010年的版本,重新编译,make的时候,还是出现原来错误!有人说是使用make realclean命令,结果尝试了一下make * realclean /安装包的目录结果没有什么作用从网上找来了这段命令的介绍,http://www.ccp4.ac.uk/peter/programming/makefile-targets.html
Makefile TargetsBelow are some empirical definitions of what each of the "standard" Makefile targets (clean, realclean, distclean and uninstall) should do:make clean - removes core, *.o, *~, a.out, *.orig, *.rej plus any other files created by the building of the program(s) (except of course the executable(s))make realclean - does make clean plus it removes the executables from the build directorymake distclean - does make realclean plus removes Makefile, config.* files, C source files produced by configure and so on. Basically, after distclean only the originally distributed files should be left behindmake uninstall - delete all installed files created by the install target. That's all, and doesn't depend on any of the other targets, so not actually as serious as it sounds.So in principle the complete clean-up-for-starting-over prescription is (in top CCP4 directory) to do:> make uninstall> make distclean
最后尝试了一下 make distclean没有报错,接着重新编译,make,竟然过去了,然后make install完成后 ,检查了一下 pfm的安装状态/usr/local/sbin/php-fpm -t结果出现如图错误:于是cp /var/php-5.3.13/sapi/fpm/php-fpm.conf /usr/local/etc/再测时,已经可以运行了。
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: