LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 775|回复: 0

安装php5遇到的问题

[复制链接]
发表于 2006-6-6 21:13:09 | 显示全部楼层 |阅读模式
提示如下:
[PHP]checking whether the C compiler (gcc -O2 -mcpu=i686 -pipe -mieee ) works... no
configure: error: installation or configuration problem: C compiler cannot create executables.

!!! Please attach the config.log to your bug report:
!!! /var/tmp/portage/t1lib-5.0.2/work/t1lib-5.0.2/config.log

!!! ERROR: media-libs/t1lib-5.0.2 failed.
!!! Function econf, Line 485, Exitcode 0
!!! econf failed
!!! If you need support, post the topmost build error, NOT this status message.
[/PHP]

/var/tmp/portage/t1lib-5.0.2/work/t1lib-5.0.2/config.log内容如下:
[PHP]
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

configure:726: checking whether make sets ${MAKE}
configure:755: checking for gcc
configure:868: checking whether the C compiler (gcc -O2 -mcpu=i686 -pipe -mieee ) works
configure:884: gcc -o conftest -O2 -mcpu=i686 -pipe -mieee   conftest.c  1>&5
cc1: error: invalid option `ieee'
configure: failed program was:

#line 879 "configure"
#include "confdefs.h"

main(){return(0);}
[/PHP]


我知道这是一个老问题,我也找到了一些解决方法,如下:
缺省地,configure挑选c++作为编译器名字并用-lg++选项的GNU c++链接。如果你正在使用gcc,这个特性在配置期间导致如下问题:
[PHP]
configure: error: installation or configuration problem:
C++ compiler cannot create executables.
[/PHP]
你可能也在编译期间看到g++、libg++或libstdc++相关的问题。这些问题的一个原因是你可能没有g++,或你可能有g++但无libg++或libstdc++。看一下“config.log”文件。它应该包含你的c++编译器不能工作的准确原因!为了解决这些问题,你可以使用gcc作为你的C++编译器。试试设置环境变量CXX为"gcc -O3"。例如:
[PHP]
shell>CXX="gcc -O3" ./configure
[/PHP]
它能工作,因为gcc象g++一样编译C++源代码,但缺省地它不链接libg++或libstdc++。解决这些问题的其他方法当然是安装g++、libg++和libstdc++。

可是我还是不知道咋解决?
我是用的gentoo2005.1,g++有,libg++和libstdc++没有
装软件包都是直接emerge的,怎么知道libg++和libstdc++是在哪些软件包里头呢?
用了CXX="gcc -O3" ./configure,好像不行,呜呜

哪位知道怎么解决的给个明白的解决方法好吗?谢谢了
您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表