+ -
当前位置:首页 → 问答吧 → 交叉编译后不能运行,什么问题呢?

交叉编译后不能运行,什么问题呢?

时间:2006-01-19

来源:互联网

交叉编译后下载到板子上怎么不可以用啊?

--------------------------------------------------------------------------------

bootloader-------vivi
kernel-------------2.4.18
fs-------------------cramfs
文件系统可以跑起来,但是很简单的应用程序“hello,World”都不能执行什么原因?输出如下:

..................
Initializing USB Mass Storage driver...
usb.c: registered new driver u
USB Mass Storage support registered.
mice: PS/2 mouse device common for all mice
NET4: Linux TCP/IP 1.0 for NET4.0
IP Protocols: ICMP, UDP, TCP, IGMP
IP: routing cache hash table of 512 buckets, 4Kbytes
TCP: Hash tables configured (established 4096 bind 4096)
NET4: Unix domain sockets 1.0/SMP for Linux NET4.0.
NetWinder Floating Point Emulator V0.95 (c) 1998-1999 Rebel.com
Root-NFS: No NFS server available, giving up.
VFS: Unable to mount root fs via NFS, trying floppy.
VFS: Mounted root (cramfs filesystem).
Mounted devfs on /dev
Freeing init memory: 76K
hub.c: USB new device connect on bus1/2, assigned device number 2
usb.c: USB device not accepting new address=2 (error=-110)
mount /etc as ramfs
hub.c: USB new device connect on bus1/2, assigned device number 3
usb.c: USB device not accepting new address=3 (error=-110)
re-create the /etc/mtab entries
init started: BusyBox v1.00 (2006.01.17-13:17+0000) multi-call binary
Starting pid 18, console /dev/ttyS0: '/etc/init.d/rcS'
exec: 3: /usr/etc/rc.local?not found

Please press Enter to activate this console.
Starting pid 21, console /dev/ttyS0: '/bin/sh'


BusyBox v1.00 (2006.01.17-13:17+0000) Built-in shell (ash)
Enter 'help' for a list of built-in commands.

/ # cd /usr/
/usr # ./hello
./hello: error while loading shared libraries: libc.so.6: cannot open shared obj
ect file: No such file or directory
/usr #
这是什么原因阿,是交叉编译有问题,还是应用程序的问题啊,其他的交叉编译后的程序也有问题,有时候提示是librt.so.1的问题,问题也是一样的。大家帮忙阿。


另外我还想问一下交叉编译用到的库是怎么找到的阿,怎么定义具体位置,只要export 工具链的路径就可以了么?      

作者: noreason   发布时间: 2006-01-19

请问如何把自己的程序放到cramfs格式的文件系统镜像中?要用到什么工具来生成么?谢谢了      

作者: gothicane   发布时间: 2006-04-14

热门下载

更多