2009-04-01 10:02:08 gdb (host) won't compile
Ralph Bertelsmann (GERMANY)
Message: 71955
Hello everyone,
i am encountering the following problem in my uClinux-dist-2008R1.5-RC3, configured for Surveyor SRV1 BF537:
Selecting "gdb (host)" with following "make" is leading to:
CC util-linux/more.o
CC util-linux/mount.o
CC util-linux/umount.o
AR util-linux/lib.a
LINK busybox_unstripped
bfin-uclinux-strip: busybox_unstripped: File format not recognized
make[3]: Verlasse Verzeichnis '/home/ralph/robo/uClinux-dist-2008R1.5-RC3/user/busybox'
make[2]: Verlasse Verzeichnis '/home/ralph/robo/uClinux-dist-2008R1.5-RC3/user'
make[1]: *** [all] Fehler 2
make[1]: Verlasse Verzeichnis '/home/ralph/robo/uClinux-dist-2008R1.5-RC3/user'
make: *** [subdirs] Fehler 1
ralph@scooter:~/robo/uClinux-dist-2008R1.5-RC3$
A 2nd make, without changing anything, throws:
checking for flex... no
checking for lex... no
checking for makeinfo... makeinfo
../configure: 2959: -o: not found
*** The command ' -o conftest -DEMBED -D__uClinux__ -I/home/ralph/robo/uClinux-dist-2008R1.5-RC3 -mcpu=bf537-0.2 -Wl,-elf2flt -mcpu=bf537-0.2 conftest.c' failed.
*** You must set the environment variable CC to a working compiler.
make[3]: *** [host/build] Fehler 1
make[3]: Verlasse Verzeichnis '/home/ralph/robo/uClinux-dist-2008R1.5-RC3/user/gdb'
make[2]: *** [gdb] Fehler 2
make[2]: *** Warte auf noch nicht beendete Prozesse...
make[3]: Verlasse Verzeichnis '/home/ralph/robo/uClinux-dist-2008R1.5-RC3/user/busybox'
make[2]: Verlasse Verzeichnis '/home/ralph/robo/uClinux-dist-2008R1.5-RC3/user'
make[1]: *** [all] Fehler 2
make[1]: Verlasse Verzeichnis '/home/ralph/robo/uClinux-dist-2008R1.5-RC3/user'
make: *** [subdirs] Fehler 1
ralph@scooter:~/robo/uClinux-dist-2008R1.5-RC3$
So i added the following line to /user/gdb/configure
CC=bfin-uclinux-gcc
The next make ends up with:
checking for bfin-uclinux-objcopy... bfin-uclinux-objcopy
checking for bfin-uclinux-objdump... bfin-uclinux-objdump
checking for bfin-uclinux-ar... bfin-uclinux-ar
checking for bfin-uclinux-as... bfin-uclinux-as
checking for bfin-uclinux-dlltool... no
checking for bfin-uclinux-ld... bfin-uclinux-ld
checking for bfin-uclinux-nm... bfin-uclinux-nm
checking for bfin-uclinux-ranlib... bfin-uclinux-ranlib
checking for bfin-uclinux-windres... no
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[3]: Verlasse Verzeichnis '/home/ralph/robo/uClinux-dist-2008R1.5-RC3/user/busybox'
touch host/build
make -C build
make: Betrete ein unbekanntes Verzeichnis
make: *** build: No such file or directory. Schluss.
make: Verlasse ein unbekanntes Verzeichnis
make[3]: *** [all] Fehler 2
make[3]: Verlasse Verzeichnis '/home/ralph/robo/uClinux-dist-2008R1.5-RC3/user/gdb'
make[2]: *** [gdb] Fehler 2
make[2]: Verlasse Verzeichnis '/home/ralph/robo/uClinux-dist-2008R1.5-RC3/user'
make[1]: *** [all] Fehler 2
make[1]: Verlasse Verzeichnis '/home/ralph/robo/uClinux-dist-2008R1.5-RC3/user'
make: *** [subdirs] Fehler 1
ralph@scooter:~/robo/uClinux-dist-2008R1.5-RC3$
I just can't see what the problem is ...
Sorry for the german code snippets, hope they help anyway.
Any help is appreciated! =)
Thanks in advance!
TranslateQuoteReplyEditDelete
2009-04-01 10:14:23 Re: gdb (host) won't compile
Mike Frysinger (UNITED STATES)
Message: 71958
why are you trying to build gdb(host) in the first place ? gdb is integrated into the toolchain, and it is not possible to run a host gdb on the board.
QuoteReplyEditDelete
2009-04-02 12:00:28 Re: gdb (host) won't compile
Ralph Bertelsmann (GERMANY)
Message: 72064
Hmm ok,
i was looking for a way to debug my programs on my blackfin (obviously ;)).
I tested the gdbserver, it is working well, but i ran into some problems:
The Srv1 Robot only has two UART channels to communicate. No ethernet.
It is using a matchport module to convert UART to ethernet.
I open a telnet connection on UART0 and from there i start the Gdbserver on UART1.
Debugging with gdb from my development machine works great.
But now here is my problem: I have written a program that gets data from UART1.
So i only can use UART1 for receiving data OR for debugging.
I cannot debug the program while it es receiving data.
So i thought to use gdb directly over telnet on the blackfin board, to keep the second UART free for data exchange.
So that is not possible? Grmpf
Maybe someone has an idea for a workaround?
TranslateQuoteReplyEditDelete
2009-04-02 12:26:19 Re: gdb (host) won't compile
Mike Frysinger (UNITED STATES)
Message: 72065
might be able to use ppp to create a virtual network link on UART0 (then you can run gdbserver over the "network" as well as telnet), but i dont know SRV1 specifics to know how ...
QuoteReplyEditDelete
2009-04-06 03:46:30 Re: gdb (host) won't compile
Ralph Bertelsmann (GERMANY)
Message: 72200
Thank you Mike,
i often heard that writing an ethernet over uart driver would be best,
because the main disadvantage of the surveyor srv1 robot is the missing (real) ethernet interface.
...
So no chance to go with Gdb(Target)/Gdb(Host)?
TranslateQuoteReplyEditDelete
2009-04-06 03:58:47 Re: gdb (host) won't compile
Mike Frysinger (UNITED STATES)
Message: 72201
i dont know what you mean by "gdb(target)/gdb(host)", but if you're referring to gdb running on the board, then the answer is no. i'm not sure it's even possible with no-mmu (ive never seen a Linux port that supported it), but it would certainly be a significant undertaking.
i dont suppose it'd be feasible to change your application read from the uart<->ethernet ?