LinuxSir.cn,穿越时空的Linuxsir!

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

LFS安装阶段glibc编译后测试出错,前功尽弃?

[复制链接]
发表于 2006-2-23 20:49:35 | 显示全部楼层 |阅读模式
第一次装LFS,机器速度慢,整了一天了才装到这个地方,整个安装过程严格按照LFS BOOK 6.1中文版操作,这是遇到的第一个错误,也是致命的。

如果我还想继续装LFS,我最初编译好的tools文件夹下的工具是否不必再重新编译,不知如何再利用..........

现在把错误提示贴出来,烦劳高手指点下可能是哪里出问题了,如何补救,不剩感激!
make check   错误如下

> /sources/glibc-build/libio/tst-fopenloc.check
/sources/glibc-build/malloc/mtrace /sources/glibc-build/libio/tst-fopenloc.mtrace >> /sources/glibc-build/libio/tst-fopenloc.check
/bin/sh: /sources/glibc-build/malloc/mtrace: No such file or directory
make[2]: *** [/sources/glibc-build/libio/tst-fopenloc.check] Error 127
make[2]: Leaving directory `/sources/glibc-2.3.4/libio'
make[1]: *** [libio/tests] Error 2
make[1]: Leaving directory `/sources/glibc-2.3.4'
make: *** [check] Error 2



make install  错误如下

mv -f termios.c.texi.new termios.c.texi
pwd=`pwd`; \
no libm-err-tab.pl $pwd/.. > libm-err-tmp
/bin/sh: no: command not found
make[2]: *** [stamp-libm-err] Error 127
make[2]: Leaving directory `/sources/glibc-2.3.4/manual'
make[1]: *** [manual/subdir_install] Error 2
make[1]: Leaving directory `/sources/glibc-2.3.4'
make: *** [install] Error 2

测试程序
root:/sources/binutils-build# echo 'main(){}' > dummy.
root:/sources/binutils-build# cc dummy.c
/tools/lib/gcc/i686-pc-linux-gnu/3.4.3/../../../../i686-pc-linux-gnu/bin/ld: cannot find /lib/libc.so.6
collect2: ld returned 1 exit status
发表于 2006-2-23 20:56:46 | 显示全部楼层
问题应该是 你的 perl 安装出错,这个错误之前有人碰到了。退出 chroot 环境重装 perl 试试。
回复 支持 反对

使用道具 举报

 楼主| 发表于 2006-2-23 21:28:59 | 显示全部楼层
Post by 终极幻想
问题应该是 你的 perl 安装出错,这个错误之前有人碰到了。退出 chroot 环境重装 perl 试试。


果然是啊!!!!!!!!不知道怎么修,
我干脆再找时间万全重新编译一次。

Uh-oh, the C compiler 'cc' doesn't seem to be working.
/mnt/lfs/tools/bin/../lib/gcc/i686-pc-linux-gnu/3.4.3/../../../../i686-pc-linux-gnu/bin/ld: cannot find -lgcc_s
collect2: ld returned 1 exit status
Uh-oh, the C compiler 'cc' doesn't seem to be working.
You need to find a working C compiler.
Either (purchase and) install the C compiler supplied by your OS vendor,
or for a free C compiler try http://gcc.gnu.org/
I cannot continue any further, aborting.
回复 支持 反对

使用道具 举报

发表于 2006-2-23 23:19:39 | 显示全部楼层
Post by traveller_2

make install  错误如下

mv -f termios.c.texi.new termios.c.texi
pwd=`pwd`; \
no libm-err-tab.pl $pwd/.. > libm-err-tmp
/bin/sh: no: command not found
make[2]: *** [stamp-libm-err] Error 127
make[2]: Leaving directory `/sources/glibc-2.3.4/manual'
make[1]: *** [manual/subdir_install] Error 2
make[1]: Leaving directory `/sources/glibc-2.3.4'
make: *** [install] Error 2


这个问题我也碰到了,perl似乎是有问题,但是我在命令行可以运行perl,所以我就把 /sources/glibc-2.3.4/manual 下的Makefile中的 “$(PERL) libm-err-tab.pl $pwd/.. > libm-err-tmp ” 中的 $(PERL) 改成 perl ,然后就ok了,但是具体原因不知……
回复 支持 反对

使用道具 举报

 楼主| 发表于 2006-2-24 07:33:05 | 显示全部楼层
lfs:/mnt/lfs/sources/perl-5.8.6$ ./configure.gnu --prefix=/tools -Dstatic_ext='IO Fcntl POSIX'
sh Configure -ds -e -Dprefix=/tools -Dstatic_ext=IO Fcntl POSIX
First let's make sure your kit is complete.  Checking...
Would you like to see the instructions? [n]
Locating common programs...
Checking compatibility between /tools/bin/echo and builtin echo (if any)...
Symbolic links are supported.
Checking how to test for symbolic links...
Your builtin 'test -h' may be broken.
Trying external '/tools/bin/test -h'.
You can test for symbolic links with '/tools/bin/test -h'.
Good, your tr supports [:lower:] and [:upper:] to convert case.
Using [:upper:] and [:lower:] to convert case.
3b1          dos_djgpp      isc_2         os2           svr4
aix          dynix          linux         os390         svr5
aix_3        dynixptx       lynxos        os400         ti1500
aix_4        epix           machten       posix-bc      titanos
altos486     esix4          machten_2     powerux       ultrix_4
amigaos      fps            mint          qnx           umips
apollo       freebsd        mips          rhapsody      unicos
atheos       genix          mpc           sco           unicosmk
aux_3        gnu            mpeix         sco_2_3_0     unisysdynix
beos         greenhills     ncr_tower     sco_2_3_1     utekv
bsdos        hpux           netbsd        sco_2_3_2     uts
convexos     i386           newsos4       sco_2_3_3     uwin
cxux         irix_4         next_3        sco_2_3_4     vmesa
cygwin       irix_5         next_3_0      solaris_2     vos
darwin       irix_6         next_4        stellar
dcosx        irix_6_0       nonstopux     sunos_4_0
dec_osf      irix_6_1       openbsd       sunos_4_1
dgux         isc            opus          super-ux
Which of these apply, if any? [linux]

You don't have an ELF gcc.  I will use dld if possible.  If you are
using a version of DLD earlier than 3.2.6, or don't have it at all, you
should probably upgrade. If you are forced to use 3.2.4, you should
uncomment a couple of lines in hints/linux.sh and restart Configure so
that shared libraries will be disallowed.


Disabling ndbm.  This will generate a Whoa There message in Configure.
Read hints/linux.sh for further information.
Operating system name? [linux]
Operating system version? [2.6.15.3]
Build Perl for SOCKS? [n]
Use the PerlIO abstraction layer? [y]
Build a threading Perl? [n]
Build Perl for multiplicity? [n]
Use which C compiler? [cc]
/mnt/lfs/tools/bin/../lib/gcc/i686-pc-linux-gnu/3.4.3/../../../../i686-pc-linux-gnu/bin/ld: cannot find -lgcc_s
collect2: ld returned 1 exit status
Uh-oh, the C compiler 'cc' doesn't seem to be working.
/mnt/lfs/tools/bin/../lib/gcc/i686-pc-linux-gnu/3.4.3/../../../../i686-pc-linux-gnu/bin/ld: cannot find -lgcc_s
collect2: ld returned 1 exit status
Uh-oh, the C compiler 'cc' doesn't seem to be working.
You need to find a working C compiler.
Either (purchase and) install the C compiler supplied by your OS vendor,
or for a free C compiler try http://gcc.gnu.org/
I cannot continue any further, aborting.
回复 支持 反对

使用道具 举报

发表于 2006-2-24 07:49:38 | 显示全部楼层
你的gcc好像被你破坏了。

你现在是在哪一步出错的?把号码(例如6.9) 告诉我。

调整了工具链没(6.12)?你有没有运行那个 Stripping(5.33) ?
回复 支持 反对

使用道具 举报

发表于 2006-2-24 13:10:17 | 显示全部楼层
从哪里跌倒就从哪里站起来。
LFS不存在前功尽弃,除非你前面有问题,当时没有发现而已。
只要保证前面的正确,前面的工作一个都不会白做的:)

哪里坏了,就从哪里开始,没有必要重头来的。
回复 支持 反对

使用道具 举报

 楼主| 发表于 2006-2-24 23:02:43 | 显示全部楼层
谢最终幻想关照!
6.11. Glibc-2.3.4编译安装才发现错误的,但当时我直接就进行来下一步,6.12. 再次调整工具链,5.33. Stripping (去掉调试符号,清理垃圾)也被我运行了,不知道后果会是什么。

我又从新进行来一次编译,目前刚进入第六章安装基本的系统软件阶段。
在第五章的软件安装过程中提供来许多可选的测试make check ,有些我没有运行,怕测试化费太多时间,因为要熄灯,无法24小时开机..........应当不是都需要测试吧?

第五章编译完后我备份了一下辛苦编译得来的 /mnt/lfs/tools/  
下次如果第六章出问题,是不是可以直接吧tools恢复使用?
( /mnt/lfs/tools/ 经过命令cp -R拷贝后不知为何变大了:
156M    /mnt/lfs/tools/
169M    /home/lfs/tools/
我是不是菜到还不能去尝试LFS............)
回复 支持 反对

使用道具 举报

 楼主| 发表于 2006-2-24 23:03:36 | 显示全部楼层
Post by good02xaut
从哪里跌倒就从哪里站起来。
LFS不存在前功尽弃,除非你前面有问题,当时没有发现而已。
只要保证前面的正确,前面的工作一个都不会白做的:)

哪里坏了,就从哪里开始,没有必要重头来的。


多谢指点,菜鸟学习中...........
回复 支持 反对

使用道具 举报

发表于 2006-2-24 23:22:38 | 显示全部楼层
我也是刚刚开始,大家一起成长:)
第5章的make check 没有什么实际用处。
重点在第6章里面。
回复 支持 反对

使用道具 举报

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

本版积分规则

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