LinuxSir.cn,穿越时空的Linuxsir!

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

我刚开始进行第五章出现一些问题.编译出错

[复制链接]
发表于 2005-3-9 10:20:10 | 显示全部楼层 |阅读模式
1.我用新用户lfs登录了之后无法编译,说我有错:
-bash-2.05b$ cd /mnt/lfs/sources
-bash-2.05b$ cd binutils-build
-bash-2.05b$ cd binutils-2.14
-bash-2.05b$ ../binutils-2.14/configure \
>     --prefix=/tools --disable-nls
../binutils-2.14/configure: line 422: ./config.log: Permission denied
-bash-2.05b$
大家看看这是怎么回事啊?
我的系统是红帽9,编译lfs5.0

当我用root登进取执行刚才的编译明令时:
[root@localhost binutils-build]# cd binutils-2.14
[root@localhost binutils-2.14]# ../binutils-2.14/configure \
>     --prefix=/tools --disable-nls
loading cache ./config.cache
checking host system type... i686-pc-linux-gnu
checking target system type... i686-pc-linux-gnu
checking build system type... i686-pc-linux-gnu
../binutils-2.14/configure: line 2206: cc: command not found
*** The command 'cc -o conftest -g   conftest.c' failed.
*** You must set the environment variable CC to a working compiler.

这种情况该怎么办啊.我是按步就班照着文档来的.

是不是我的系统内核太新了??

谢谢个位哥哥啊
发表于 2005-3-9 10:33:59 | 显示全部楼层
兄弟,看
-bash-2.05b$ ../binutils-2.14/configure \
> --prefix=/tools --disable-nls
../binutils-2.14/configure: line 422: ./config.log: Permission denied
                     ^^^^^^
好像是权限不对,
你是用ROOT解压的源代码还是用LFS用户解压的源代码?
还有
-bash-2.05b$ cd binutils-2.14
-bash-2.05b$ ../binutils-2.14/configure \
这是什么意思,
好像是上面两个命令好像不对。


你看看我写的自动编译的脚本吧。
http://bbs.linuxsir.cn/showthread.php?t=180934
回复 支持 反对

使用道具 举报

发表于 2005-3-9 13:34:17 | 显示全部楼层
没安装gcc编译器吧。
rpm -qa |grep gcc
看看有没有返回信息。
回复 支持 反对

使用道具 举报

 楼主| 发表于 2005-3-10 10:49:17 | 显示全部楼层
谢谢两位哥哥啊. 我今晚上着你们说的看看
回复 支持 反对

使用道具 举报

 楼主| 发表于 2005-3-10 10:54:10 | 显示全部楼层
[root@localhost root]# rpm -qa |grep gcc
libgcc-3.2.2-5
compat-gcc-7.3-2.96.118
compat-gcc-c++-7.3-2.96.118
[root@localhost root]#

这是返回信息,应该是装了gcc 了把
回复 支持 反对

使用道具 举报

 楼主| 发表于 2005-3-10 10:56:30 | 显示全部楼层
我好像是用root图形化解压的.呵呵,我知道错误了,在来.
晚上好好试试
谢谢啊,不懂积蓄问你们
回复 支持 反对

使用道具 举报

发表于 2005-3-10 12:08:13 | 显示全部楼层
没有gcc

如果是RH系列的话,安装光盘上的开发工具。
回复 支持 反对

使用道具 举报

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

本版积分规则

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