LinuxSir.cn,穿越时空的Linuxsir!

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

编译 U-boot-1.1.0 的问题

[复制链接]
发表于 2007-1-17 09:42:05 | 显示全部楼层 |阅读模式
想移植U-boot
书上说,找个好编译的,看能成功不,我选了 smdk2400
编译时出现了错误:

/usr/local/arm/bin/../lib/gcc-lib/arm-linux/3.2/../../../../arm-linux/bin/ld: cannot find -lfloat

我的交叉编译工具为:cross-3.2
goole了一下,貌似我的工具链缺某某,怎么搞定呢?


编译时的详细信息如下:

Configuring for smdk2400 board...
[root@localhost u-boot-1.1.0]# make
make[1]: Entering directory `/home/lnight/Bootloader/u-boot-1.1.0/tools'
make[1]: `.depend' is up to date.
make[1]: Leaving directory `/home/lnight/Bootloader/u-boot-1.1.0/tools'
make[1]: Entering directory `/home/lnight/Bootloader/u-boot-1.1.0/examples'
make[1]: `.depend' is up to date.
make[1]: Leaving directory `/home/lnight/Bootloader/u-boot-1.1.0/examples'
make[1]: Entering directory `/home/lnight/Bootloader/u-boot-1.1.0/post'
make[1]: `.depend' is up to date.
make[1]: Leaving directory `/home/lnight/Bootloader/u-boot-1.1.0/post'
make[1]: Entering directory `/home/lnight/Bootloader/u-boot-1.1.0/post/cpu'
make[1]: `.depend' is up to date.
make[1]: Leaving directory `/home/lnight/Bootloader/u-boot-1.1.0/post/cpu'
make -C tools all
make[1]: Entering directory `/home/lnight/Bootloader/u-boot-1.1.0/tools'
gcc -g -Wall -pedantic -I../include -I.. -DTEXT_BASE=0x0CF80000 -DUSE_HOSTCC -O -c envcrc.c
gcc -g  -I../include -I.. -DTEXT_BASE=0x0CF80000 -DUSE_HOSTCC -c environment.c
gcc -Wall -pedantic -I../include -I.. -DTEXT_BASE=0x0CF80000 -DUSE_HOSTCC -O -o envcrc envcrc.o crc32.o environment.o
make[1]: Leaving directory `/home/lnight/Bootloader/u-boot-1.1.0/tools'
make -C examples all
make[1]: Entering directory `/home/lnight/Bootloader/u-boot-1.1.0/examples'
arm-linux-gcc -g  -Os   -fno-strict-aliasing  -fno-common -ffixed-r8 -mshort-load-bytes -msoft-float -D__KERNEL__ -DTEXT_BASE=0x0CF80000 -I/home/lnight/Bootloader/u-boot-1.1.0/include -fno-builtin -ffreestanding -nostdinc -isystem /usr/local/arm/bin/../lib/gcc-lib/arm-linux/3.2/include -pipe  -DCONFIG_ARM -D__ARM__ -mapcs-32 -march=armv4 -Wall -Wstrict-prototypes -g  -Os   -fno-strict-aliasing  -fno-common -ffixed-r8 -mshort-load-bytes -msoft-float -D__KERNEL__ -DTEXT_BASE=0x0CF80000 -I/home/lnight/Bootloader/u-boot-1.1.0/include -fno-builtin -ffreestanding
-nostdinc -isystem /usr/local/arm/bin/../lib/gcc-lib/arm-linux/3.2/include -pipe  -DCONFIG_ARM -D__ARM__ -mapcs-32 -march=armv4 -I.. -Bstatic -T /home/lnight/Bootloader/u-boot-1.1.0/board/smdk2400/u-boot.lds -Ttext 0x0CF80000   hello_world.c   -o hello_world
/usr/local/arm/bin/../lib/gcc-lib/arm-linux/3.2/../../../../arm-linux/bin/ld: cannot find -lfloat
collect2: ld returned 1 exit status
make[1]: *** [hello_world] Error 1
make[1]: Leaving directory `/home/lnight/Bootloader/u-boot-1.1.0/examples'
发表于 2007-1-17 18:15:06 | 显示全部楼层
在make前,

执行make  depend试试
回复 支持 反对

使用道具 举报

 楼主| 发表于 2007-1-18 14:10:37 | 显示全部楼层
看了几篇别人移植 U-boot 的贴
发现有位在 make  ***_config 前执行了   make  clobber 语句
我也执行了,好了!

错误原因至今没搞懂……还是日后研究。

感谢楼上建议,下次遇到同类问题试   make depend   先.
回复 支持 反对

使用道具 举报

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

本版积分规则

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