[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[microblaze-uclinux] Busybox elf2flt problem
Hi,
I put together a system based on MB uClinux a couple of months ago.
During the final phase when I added a couple of more commands to Busybox
I ran into a strange problem that I relate to the elf2flt conversion of
the busybox binary.
The symptoms are:
The "vi" command doesn't work. If I run just busybox I get the
following output:
BusyBox v1.00 (2006.04.10-09:12+0000) multi-call binary
Usage: busybox [function] [arguments]...
or: [function] [arguments]...
BusyBox is a multi-call binary that combines many common Unix
utilities into a single executable. Most people will create a
link to busybox for each function they wish to use, and BusyBox
will act like whatever it was invoked as.
Currently defined functions:
[, basename, busybox, cat, chmod, chown, chroot, clear, cp, date,
dd, df, dmesg, echo, false, free, ftpget, hostname, ifconfig,
init, insmod, kill, killall, klogd, ln, ls, lsmod, mkdir, mkfifo,
mknod, modprobe, more, mount, msh, mv, od, ping, ps, pwd, reboot,
reset, rm, rmdir, rmmod, route, sh, sleep, stty, sync, syslogd,
tar, test, time, touch, true, umount, uname, uptime, , wget, yes
As you can see the "vi" function is missing. When I started to dig deeper
into the busybox flt binary I realized that the the const char* name for
the "vi" entry in the applets[] array is pointing way out in the blue!
If I try to include differnt functions (applets) in busybox I get other
applets falling away. It's always some of the ones in the end of the
applets[] array.
It gets even more strange when I was debugging this and added some
printouts in run_applet_by_name() and other functions related to finding
the approporiate applet and excetuing it's main method. Then, it worked,
that is, the "name" pointer was pointing at the right place.
It is possible to modifiy the "name" pointer to point to the right place
in the flat binary and then of course busyboxs works as expected.
I've been using the microblaze-gcc-toolchain version 20060213 a and
20051121. The uClinux version was checked out from the official uClinux
CVS a couple of months ago. I've also tried to update the busybox source
to the latest from the CVS a couple of weeks ago without success.
I can't say if this is a Microblaze related problem or not, but I can
say I haven't experienced anything similar on the ARM7 target.
Best regards,
PH
--
Per-Henrik Persson epost: ph@xxxxxxxxxxx
telefon: 0733-20 71 26 hemsida: www.whatever.nu
___________________________
microblaze-uclinux mailing list
microblaze-uclinux@xxxxxxxxxxxxxx
Project Home Page : http://www.itee.uq.edu.au/~jwilliams/mblaze-uclinux
Mailing List Archive : http://www.itee.uq.edu.au/~listarch/microblaze-uclinux/