我在目标和CodeSourcery IDE上使用gdbserver.我的硬件是带有omap3530的gumstix.
我可以在我的主应用程序中单步执行代码,但如果我尝试进入共享库中的函数,我将获得内存地址并终止调试器.
这是我的库,它被编译并复制到目标系统上的/ lib文件夹.(它有调试符号)我试图使用.gbdinit文件来设置solib-absolute-prefix / lib
以下是gdb跟踪的警告:
903,056 13-gdb-set sysroot-on-target /lib 903,065 13^done 903,065 (gdb) 903,065 14-target-select remote 192.168.1.101:2345 903,114 =thread-group-started,id="i1",pid="42000" 903,114 =thread-created,id="1",group-id="i1" 903,115 15-list-thread-groups --available 903,120 16-list-thread-groups 903,128 &"warning: Unable to find dynamic linker breakpoint function.\nGDB will be unable to debug shared library initializers\nand track explicitly loaded dynamic code." 903,128 &"\n"
这导致
903,395 &"Error while mapping shared library sections:\n" 903,397 &"/lib/libCoreLib.so: Invalid argument.\n" 903,399 =library-loaded,id="/lib/libCoreLib.so",target-name="/lib/libCoreLib.so",hostname="/lib/libCoreLib.so",low-address="0x0",high-address="0x0",symbols-loaded="0",thread-group="i1"@H_404_14@