LinuxSir.cn,穿越时空的Linuxsir!

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

gcc安装求助!

[复制链接]
发表于 2005-4-3 21:52:35 | 显示全部楼层 |阅读模式
安装GCC时出错:/configure --prefix=/usr/local/gcc-3.4.1 --enable-threads=posix --disable-checking --enable--long-long --host=i386-redhat-linux --with-system-zlib --enable-languages=c,c++,java
loading cache ./config.cache
checking host system type... i386-redhat-linux-gnu
checking target system type... i386-redhat-linux-gnu
checking build system type... i386-redhat-linux-gnu
checking for a BSD compatible install... /usr/bin/install -c
*** This configuration is not supported in the following subdirectories:
     target-libf2c target-libobjc
    (Any other directories should still work fine.)
./configure: line 2332: cc: command not found
*** The command 'cc -o conftest -g   conftest.c' failed.
*** You must set the environment variable CC to a working compiler.


这是什么意思,要安装C环境么?怎么安呢?
我的是RED HAT 9.0 AMD 2000+
发表于 2005-4-3 22:35:50 | 显示全部楼层
你下载gcc源码安装的么?
如果你要--enable-languages=c,c++,java,应该同时需要gcc-core和gcc-c++两个包,并且解压到同一目录下。
回复 支持 反对

使用道具 举报

 楼主| 发表于 2005-4-3 22:48:14 | 显示全部楼层
出错信息最后一句话是:You must set the environment variable CC to a working compiler.
这个应该怎么解决呢?
回复 支持 反对

使用道具 举报

发表于 2005-4-3 23:06:34 | 显示全部楼层
when configuring a native system, either cc or gcc must be in your path or you must set CC in your environment before running configure. Otherwise the configuration scripts may fail.
回复 支持 反对

使用道具 举报

 楼主| 发表于 2005-4-4 11:50:32 | 显示全部楼层
but how can I set the cc environmet?what should I do?can you show me step by step?
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

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