LinuxSir.cn,穿越时空的Linuxsir!

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

chroot后用不了命令 相关 !![gcc}

[复制链接]
发表于 2003-7-5 20:27:11 | 显示全部楼层 |阅读模式
chroot /lfs /stage1/bin/env -i \
    HOME=/root TERM=$TERM PS1='\u:\w\$ ' \
    PATH=/bin:/usr/bin:/sbin:/usr/sbin:/stage1/bin \
    /stage1/bin/bash --login


ls chown 等等的都用不了 cd 能行

显示: “no such dir.... or file ” 这个提示


[root@freel root]# file /lfs/stage1/bin/bash
/lfs/stage1/bin/bash: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV),
for GNU/Linux 2.0.0, dynamically linked (uses shared libs), stripped
[root@freel root]#

bash没问题吧?

我怎么能知道是什么问题呢?
发表于 2003-7-5 21:05:55 | 显示全部楼层
应该是第一阶段装bash的时候出了问题,重新装
 楼主| 发表于 2003-7-5 22:29:50 | 显示全部楼层

ldd后是这样

发表于 2003-7-5 22:53:10 | 显示全部楼层
ls和chown应该是coreutils,你重新编译一下它看看.
 楼主| 发表于 2003-7-6 08:10:38 | 显示全部楼层

find,xargs

这两个 应该是哪个包里的
 楼主| 发表于 2003-7-6 08:41:54 | 显示全部楼层

找到了

是FINDU...

费心了 !!
 楼主| 发表于 2003-7-6 10:01:14 | 显示全部楼层

GLIBC

configure: err
*** These auxiliary programs are missing or too old: gcc

*** Check the INSTALL file for required versions.

这能解决吗

难道我GCC也得重装!
发表于 2003-7-6 10:14:03 | 显示全部楼层
可能还是连接的问题?你是在哪里安装glibc?glibc有两次,要说清楚.
file /stage1/bin/gcc
ldd /stage1/bin/gcc
看看结果.
 楼主| 发表于 2003-7-6 10:16:59 | 显示全部楼层

chroot 里的 第六章

[root@freel root]# file /stage1/bin/gcc
/stage1/bin/gcc: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), for GNU/Linux 2.2.5, dynamically linked (uses shared libs), stripped
[root@freel root]#
[root@freel root]# ldd /stage1/bin/gcc
        libc.so.6 => /lib/tls/libc.so.6 (0x42000000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)
[root@freel root]#
发表于 2003-7-6 12:02:28 | 显示全部楼层
root@freel root]# ldd /stage1/bin/gcc
libc.so.6 => /lib/tls/libc.so.6 (0x42000000)
/lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)
[root@freel root]#
你这个gcc根本没有连接到/stage1里面的glibc上,当然不能用了.要再编译第五章gcc pass2
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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