LinuxSir.cn,穿越时空的Linuxsir!

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

配置GCC-3.4.0时候出现的问题

[复制链接]
发表于 2004-12-31 19:14:14 | 显示全部楼层 |阅读模式
从GCC的网站下下载了3.4.0的压缩包,解压
      % tar xzvf gcc-3.4.0.tar.gz  成功
   
  然后在与gcc-3.4.0同级目录上新建了gcc-build 的目标目录
  
   在配置的时候
  
   [aircoal@fujiang gcc-build]$ ../gcc-3.4.0/configure --prefix=/usr/local/gcc-3.4.0 --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.)
../gcc-3.4.0/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.

安装没有成功,在/usr/local/目录下也没有gcc-3.4.0这个目录,请大家指教!

在线等!!
 楼主| 发表于 2004-12-31 19:47:03 | 显示全部楼层

配置GCC-3.4.0时候出现的问题

从GCC的网站下下载了3.4.0的压缩包,解压
% tar xzvf gcc-3.4.0.tar.gz 成功

然后在与gcc-3.4.0同级目录上新建了gcc-build 的目标目录

在配置的时候

[aircoal@fujiang gcc-build]$ ../gcc-3.4.0/configure --prefix=/usr/local/gcc-3.4.0 --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.)
../gcc-3.4.0/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.

安装没有成功,在/usr/local/目录下也没有gcc-3.4.0这个目录,请大家指教!

在线等!!
发表于 2004-12-31 20:06:16 | 显示全部楼层
你必需指定一个编译器,上面已经很清楚了,有些程序需要cc而不是gcc,建一个符号链接吧,参考一下gcc how to 吧,  确定所有的dependency 都有,!!!
发表于 2004-12-31 22:36:00 | 显示全部楼层
你现有系统没有编译器吗?
提示说的不是已经很明白了吗?你什么发行版?
 楼主| 发表于 2005-1-2 16:20:11 | 显示全部楼层
re :  Sakur_Fre
    在Emacs里随便写个C程序,写好C-x C-s.然后M-x compile,接着Minibuf提示Compile cpmmand :make -hello.c 回车.没有问题之后进入"终端",默认程序所在目录,输入:gcc -o hello hello.c
提示:gcc :command not found
    C语言用gcc应该没什么问题.而问题在于我的机子上没有gcc这个编译器,装也装不上.
     ps: where  is  "gcc how to"?
 楼主| 发表于 2005-1-2 16:21:53 | 显示全部楼层
re :弥敦路九号
   至少没有gcc,而编译的时候我想用它.
   RedHat 9.0
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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