免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 2779 | 回复: 5
打印 上一主题 下一主题

gdbserver 问题 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2006-05-12 14:01 |只看该作者 |倒序浏览
在arm板子上运行gdbserver, pc上运行arm-linux-gdb

pc上的信息:
[root@localhost ffmpeg-0.4.8]# arm-linux-gdb ffmpeg
GNU gdb 6.4
Copyright 2005 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "--host=i686-pc-linux-gnu --target=arm-linux"...
(gdb) target remote 192.168.0.100:1234
Remote debugging using 192.168.0.100:1234
0x40002a90 in ?? ()
(gdb) r
The program being debugged has been started already.
Start it from the beginning? (y or n) y
Starting program: /usr/src/arm-linux/ffmpeg-0.4.8/ffmpeg
Don't know how to run.  Try "help target".
(gdb) Quit
(gdb)



arm端信息:
/ffmpeg # gdbserver 192.168.0.250:1234 ffmpeg
Process ffmpeg created; pid = 70
Listening on port 1234
Remote debugging from host 192.168.0.250
Killing inferior
/ffmpeg #


list, break, continue, next 都可以用,但是也有一些错误信息。
run调试时肯定是要用的,弄了两天也没搞定,请各位高手帮忙

[ 本帖最后由 dida_327 于 2006-5-12 14:03 编辑 ]

论坛徽章:
0
2 [报告]
发表于 2006-05-12 14:13 |只看该作者
好像gdbserver确实不能用run, 可是continue不能加参数啊,难道要改源程序,写死参数?

论坛徽章:
0
3 [报告]
发表于 2006-05-13 11:30 |只看该作者
不用r, 用c 应该可以

论坛徽章:
0
4 [报告]
发表于 2006-05-25 10:57 |只看该作者
用c是可以,把参数写死可以单步调,但是step多步就会出问题,而且无法调试多线程,一运行到创建新线程,程序就收到信号跳出。普通的gdb是可以调多线程的啊

论坛徽章:
0
5 [报告]
发表于 2006-05-26 08:19 |只看该作者
急啊,老是用printf调试,要经常传程序,废时间,另外要看大的structure,也不可能用print一个个看成员啊,就算用全局变量,无法让程序停在线程里的某个点,还是没用。到底怎么弄多线程呢

论坛徽章:
0
6 [报告]
发表于 2006-07-21 17:10 |只看该作者
就是不能用run运行,只能用continue运行,但是这样又不能带参数,无法传递参数。难道非要把程序参数写死才能调吗?有没有更好的办法,急啊,请各位不吝赐教!!先行谢过了
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP