Discussion:
Problem with arm-linux-gnueabihf-gdb
Bob Furber
2015-02-09 19:08:53 UTC
Permalink
I am trying to set up an Eclipse/CDT development environment on an
Ubuntu 14.04 (64 bit) PC to cross-compile and debug software for a
RK3188 Arm platform.

To this end, I downloaded
https://releases.linaro.org/12.10/components/toolchain/binaries/gcc-linaro-arm-linux-gnueabihf-4.7-2012.10-20121022_linux.tar.bz2,
expanded and rearranged the distribution to simplify the path to the
tools to /home/bob/Development/platforms/arm-linux-gnueabihf/bin.

With this arrangement I was able to compile a HelloWorld program without
any difficulty and the executable ran on the RK3188 Arm platform and
performed as intended.

I also copied gdbserver
(/home/bob/Development/platforms/arm-linux-gnueabihf/arm-linux-gnueabihf/debug-root/usr/bin/gdbserver)
to the RK3188 Arm platform and it could then be started remotely through
Eclipse. At least, gdbserver was assigned a pid and output "Listening on
port 2345". So far so good.

However, Eclipse was unable to launch arm-linux-gnueabihf-gdb;
outputting an error, instead:

"Could not determine GDB version using command:
/home/bob/Development/platforms/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gdb
--version
/home/bob/Development/platforms/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gdb:
error while loading shared libraries: libncurses.so.5: cannot open
shared object file: No such file or directory"

I tried running arm-linux-gnueabihf-gdb from the UpuntuPC's command line
and got a similar error:

***@myUbuntuPC:~$ sudo
Development/platforms/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gdb --version
Development/platforms/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gdb:
error while loading shared libraries: libncurses.so.5: cannot open
shared object file: No such file or directory

Can anyone point me in the right direction?

BobF
Bob Furber
2015-02-09 22:09:37 UTC
Permalink
Doh!

The clue was "error while loading shared libraries: libncurses.so.5".

I installed libncurses.so.5:

sudo apt-get install libncurses5:i386 libncurses5

..followed by apt-get update and apt-get upgrade

...gdb now runs, but gives me a whole new set of errors:

warning: Unable to find dynamic linker breakpoint function.

GDB will be unable to debug shared library initializersand track
explicitly loaded dynamic code.
warning: Could not load shared library symbols for 5 libraries, e.g.
/usr/lib/arm-linux-gnueabihf/libstdc++.so.6.
Use the "info sharedlibrary" command to see the complete listing.
Do you need "set solib-search-path" or "set sysroot"?
Cannot access memory at address 0x0

BobF
Post by Bob Furber
I am trying to set up an Eclipse/CDT development environment on an
Ubuntu 14.04 (64 bit) PC to cross-compile and debug software for a
RK3188 Arm platform.
To this end, I downloaded
https://releases.linaro.org/12.10/components/toolchain/binaries/gcc-linaro-arm-linux-gnueabihf-4.7-2012.10-20121022_linux.tar.bz2,
expanded and rearranged the distribution to simplify the path to the
tools to /home/bob/Development/platforms/arm-linux-gnueabihf/bin.
With this arrangement I was able to compile a HelloWorld program
without any difficulty and the executable ran on the RK3188 Arm
platform and performed as intended.
I also copied gdbserver
(/home/bob/Development/platforms/arm-linux-gnueabihf/arm-linux-gnueabihf/debug-root/usr/bin/gdbserver)
to the RK3188 Arm platform and it could then be started remotely
through Eclipse. At least, gdbserver was assigned a pid and output
"Listening on port 2345". So far so good.
However, Eclipse was unable to launch arm-linux-gnueabihf-gdb;
/home/bob/Development/platforms/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gdb
--version
error while loading shared libraries: libncurses.so.5: cannot open
shared object file: No such file or directory"
I tried running arm-linux-gnueabihf-gdb from the UpuntuPC's command
Development/platforms/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gdb --version
error while loading shared libraries: libncurses.so.5: cannot open
shared object file: No such file or directory
Can anyone point me in the right direction?
BobF
_______________________________________________
cross-distro mailing list
http://lists.linaro.org/mailman/listinfo/cross-distro
Loading...