LinuxSir.cn,穿越时空的Linuxsir!

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

Binutils-2.16.1 - 第一遍

[复制链接]
发表于 2007-12-14 17:02:07 | 显示全部楼层 |阅读模式
好痛苦!排查 了很多原因,到最后怕自己输入错误,特地用PUTTY copy 进去,到Binutils-2.16.1 - 第一遍,也就是5.3的时候,就出现编译错误!
很多人说有两个原因:
如果你第一遍binutils都无法编译,那么基本上可以确定是你主系统的问题,这里有两个选择:可以使用LFS的LiveCD来做主系统,这样可以尽量避免因主系统造成的问题;也可以换用binutils-2.16.1这个版本来做,这个版本的编译成功率非常高。
可是我就是用LiveCD来做主系统的,而且硬盘全阁光了,请问是怎么回事啊!
和我一起的同学也是第一次,用的这个盘,同一个步骤,能编译成功!
我的已经尝试了不下10遍了,都是同样的问题(这里应该没问题的):
cfdisk
mke2fs -jv /dev/hda1
mkswap /dev/hda2
export LFS=/mnt/lfs
mkdir -pv $LFS
mkdir -pv $LFS
mount -v -t ext3 /dev/hda1 $LFS
/sbin/swapon -v /dev/hda2
export LFS=/mnt/lfs
mkdir -pv $LFS
mkdir -v $LFS/sources
chmod -v a+wt $LFS/sources
mkdir -v $LFS/tools
ln -sv $LFS/tools /
groupadd lfs
useradd -s /bin/bash -g lfs -m -k /dev/null lfs
passwd lfs
chown -v lfs $LFS/tools
chown -v lfs $LFS/sources
su - lfs

cat > ~/.bash_profile << "EOF"
exec env -i HOME=$HOME TERM=$TERM PS1='\u:\w\$ ' /bin/bash
EOF

cat > ~/.bashrc << "EOF"
set +h
umask 022
LFS=/mnt/lfs
LC_ALL=POSIX
PATH=/tools/bin:/bin:/usr/bin
export LFS LC_ALL PATH
EOF

source ~/.bash_profile

cd $LFS/sources
tar xvf /lfs-sources/binutils-2.16.1.tar.bz2解压成功!
cd binutils-2.16.1
lfs:/mnt/lfs/sources/binutils-build$ ../binutils-2.16.1/configure --prefix=/tools --disable-nls
之后就有这样的结果 :
creating 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
checking for a BSD compatible install... /usr/bin/install -c
checking whether ln works... yes
checking whether ln -s works... yes
checking for gcc... gcc
checking whether the C compiler (gcc  ) works... yes
checking whether the C compiler (gcc  ) is a cross-compiler... no
checking whether we are using GNU C... yes
checking whether gcc accepts -g... yes
checking for gnatbind... no
checking whether compiler driver understands Ada... no
checking how to compare bootstrapped objects... cmp --ignore-initial=16 $$f1 $$f2
checking for correct version of gmp.h... no
checking for bison... bison
checking for bison... bison -y
checking for gm4... no
checking for gnum4... no
checking for m4... m4
checking for flex... flex
checking for flex... flex
checking for makeinfo... makeinfo
checking for i686-pc-linux-gnu-ar... no
checking for ar... ar
checking for i686-pc-linux-gnu-as... no
checking for as... as
checking for i686-pc-linux-gnu-dlltool... no
checking for dlltool... dlltool
checking for i686-pc-linux-gnu-ld... no
checking for ld... ld
checking for i686-pc-linux-gnu-nm... no
checking for nm... nm
checking for i686-pc-linux-gnu-ranlib... no
checking for ranlib... ranlib
checking for i686-pc-linux-gnu-windres... no
checking for windres... windres
checking for i686-pc-linux-gnu-objcopy... no
checking for objcopy... objcopy
checking for i686-pc-linux-gnu-objdump... no
checking for objdump... objdump
checking for i686-pc-linux-gnu-ar... no
checking for ar... ar
checking for i686-pc-linux-gnu-as... no
checking for as... as
checking for i686-pc-linux-gnu-dlltool... no
checking for dlltool... dlltool
checking for i686-pc-linux-gnu-ld... no
checking for ld... ld
checking for i686-pc-linux-gnu-nm... no
checking for nm... nm
checking for i686-pc-linux-gnu-ranlib... no
checking for ranlib... ranlib
checking for i686-pc-linux-gnu-windres... no
checking for windres... windres
checking whether to enable maintainer-specific portions of Makefiles... no
checking if symbolic links between directories work... yes
updating cache ./config.cache
creating ./config.status
creating Makefile

有错误码?
然后make
CONFIG_SHELL="/bin/sh" /bin/sh ./config.status --recheck
running /bin/sh ../binutils-2.16.1/configure  --prefix=/tools --disable-nls --no-create --no-recursion
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
checking for a BSD compatible install... (cached) /usr/bin/install -c
checking whether ln works... (cached) yes
checking whether ln -s works... (cached) yes
checking for gcc... (cached) gcc
checking whether the C compiler (gcc  ) works... yes
checking whether the C compiler (gcc  ) is a cross-compiler... no
checking whether we are using GNU C... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gnatbind... no
checking whether compiler driver understands Ada... (cached) no
checking how to compare bootstrapped objects... (cached) cmp --ignore-initial=16 $$f1 $$f2
checking for correct version of gmp.h... no
checking for bison... (cached) bison
checking for bison... (cached) bison -y
checking for gm4... (cached) m4
checking for flex... (cached) flex
checking for flex... (cached) flex
checking for makeinfo... (cached) makeinfo
checking for i686-pc-linux-gnu-ar... no
checking for ar... (cached) ar
checking for i686-pc-linux-gnu-as... no
checking for as... (cached) as
checking for i686-pc-linux-gnu-dlltool... no
checking for dlltool... (cached) dlltool
checking for i686-pc-linux-gnu-ld... no
checking for ld... (cached) ld
checking for i686-pc-linux-gnu-nm... no
checking for nm... (cached) nm
checking for i686-pc-linux-gnu-ranlib... no
checking for ranlib... (cached) ranlib
checking for i686-pc-linux-gnu-windres... no
checking for windres... (cached) windres
checking for i686-pc-linux-gnu-objcopy... no
checking for objcopy... (cached) objcopy
checking for i686-pc-linux-gnu-objdump... no
checking for objdump... (cached) objdump
checking for i686-pc-linux-gnu-ar... no
checking for ar... (cached) ar
checking for i686-pc-linux-gnu-as... no
checking for as... (cached) as
checking for i686-pc-linux-gnu-dlltool... no
checking for dlltool... (cached) dlltool
checking for i686-pc-linux-gnu-ld... no
checking for ld... (cached) ld
checking for i686-pc-linux-gnu-nm... no
checking for nm... (cached) nm
checking for i686-pc-linux-gnu-ranlib... no
checking for ranlib... (cached) ranlib
checking for i686-pc-linux-gnu-windres... no
checking for windres... (cached) windres
checking whether to enable maintainer-specific portions of Makefiles... no
checking if symbolic links between directories work... (cached) yes
creating ./config.status
CONFIG_FILES=Makefile CONFIG_HEADERS= /bin/sh ./config.status
creating Makefile
make: Warning: File `../binutils-2.16.1/Makefile.in' has modification time 1.4e+08 s in the future
CONFIG_SHELL="/bin/sh" /bin/sh ./config.status --recheck
running /bin/sh ../binutils-2.16.1/configure  --prefix=/tools --disable-nls --no-create --no-recursion
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
checking for a BSD compatible install... (cached) /usr/bin/install -c
checking whether ln works... (cached) yes
checking whether ln -s works... (cached) yes
checking for gcc... (cached) gcc
checking whether the C compiler (gcc  ) works... yes
checking whether the C compiler (gcc  ) is a cross-compiler... no
checking whether we are using GNU C... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gnatbind... no
checking whether compiler driver understands Ada... (cached) no
checking how to compare bootstrapped objects... (cached) cmp --ignore-initial=16 $$f1 $$f2
checking for correct version of gmp.h... no
checking for bison... (cached) bison
checking for bison... (cached) bison -y
checking for gm4... (cached) m4
checking for flex... (cached) flex
checking for flex... (cached) flex
checking for makeinfo... (cached) makeinfo
checking for i686-pc-linux-gnu-ar... no
checking for ar... (cached) ar
checking for i686-pc-linux-gnu-as... no
checking for as... (cached) as
checking for i686-pc-linux-gnu-dlltool... no
checking for dlltool... (cached) dlltool
checking for i686-pc-linux-gnu-ld... no
checking for ld... (cached) ld
checking for i686-pc-linux-gnu-nm... no
checking for nm... (cached) nm
checking for i686-pc-linux-gnu-ranlib... no
checking for ranlib... (cached) ranlib
checking for i686-pc-linux-gnu-windres... no
checking for windres... (cached) windres
checking for i686-pc-linux-gnu-objcopy... no
checking for objcopy... (cached) objcopy
checking for i686-pc-linux-gnu-objdump... no
checking for objdump... (cached) objdump
checking for i686-pc-linux-gnu-ar... no
checking for ar... (cached) ar
checking for i686-pc-linux-gnu-as... no
checking for as... (cached) as
checking for i686-pc-linux-gnu-dlltool... no
checking for dlltool... (cached) dlltool
checking for i686-pc-linux-gnu-ld... no
checking for ld... (cached) ld
checking for i686-pc-linux-gnu-nm... no
checking for nm... (cached) nm
checking for i686-pc-linux-gnu-ranlib... no
checking for ranlib... (cached) ranlib
checking for i686-pc-linux-gnu-windres... no
checking for windres... (cached) windres
checking whether to enable maintainer-specific portions of Makefiles... no
checking if symbolic links between directories work... (cached) yes
creating ./config.status
CONFIG_FILES=Makefile CONFIG_HEADERS= /bin/sh ./config.status
creating Makefile
make: Warning: File `../binutils-2.16.1/Makefile.in' has modification time 1.4e+08 s in the future
CONFIG_SHELL="/bin/sh" /bin/sh ./config.status --recheck
一直在这样的死循环????
求救阿!
 楼主| 发表于 2007-12-14 17:20:38 | 显示全部楼层
我的宿主系统:
bash, version 3.1.17(1)-release
Binutils: version 2.16.1
bzip2,  Version 1.0.3, 15-Feb-2005.
Coreutils:  5.96
diff (GNU diffutils) 2.8.1
GNU find version 4.2.27
GNU Awk 3.1.5
gcc (GCC) 4.0.3
GNU C Library stable release version 2.3.6,
grep (GNU grep) 2.5.1
gzip 1.3.5
Linux version 2.6.16.38 (gcc version 4.0.3)
GNU Make 3.80
patch 2.5.4
GNU sed version 4.1.5
tar (GNU tar) 1.15.1
回复 支持 反对

使用道具 举报

发表于 2007-12-14 17:51:19 | 显示全部楼层
看起来好像是系统时间没有设置好,用date命令查看一下
回复 支持 反对

使用道具 举报

发表于 2007-12-14 21:37:37 | 显示全部楼层
我也这样,郁闷,第一次过去了,好象没多长时间,但第二次,第三次。。。都过不去了,怎么回事呢?
回复 支持 反对

使用道具 举报

发表于 2007-12-14 22:45:08 | 显示全部楼层
手册不是建议你们另建工作目录才进行的吗?
回复 支持 反对

使用道具 举报

发表于 2007-12-14 23:38:58 | 显示全部楼层
我有cd ../binutils-build这句啊
回复 支持 反对

使用道具 举报

发表于 2007-12-15 00:12:02 | 显示全部楼层
似乎三楼说得对,时间设置好像有点问题
回复 支持 反对

使用道具 举报

发表于 2007-12-15 01:17:02 | 显示全部楼层
date之后
bash : /bin/date:cannot execute binary file
回复 支持 反对

使用道具 举报

 楼主| 发表于 2007-12-15 10:32:30 | 显示全部楼层
date 我改成现在的时间吗?为什么别人用同一张LIVECD\做的可以,我却不可以呢?
回复 支持 反对

使用道具 举报

 楼主| 发表于 2007-12-15 10:42:31 | 显示全部楼层
我好奇怪,就是用wybmk的方法 ,成功了?
但是有个问题:为什么别人同样的cd做却不用修改DATE啊,而且他两次都对!
回复 支持 反对

使用道具 举报

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

本版积分规则

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