python使用qtcreatot_Qtcreator远程调试出现“The selected build of GDB does not support Python scripting.It can...

之前使用的是Qt4.7后来换成了Qt5.x,Qtcreator的版本使用4.0,使用中发现Qtcreator远程调试出现“The selected build of GDB does not support Python scripting.It cannot be used in Qt Creator.”

意思是gdb不支持Python脚本不能再Qtcreator中使用。有问题问度娘找了半天终于发现一个能解决问题的分享一下:

sudo apt-get install gdb-multiarch

安装这个gdb工具。然后Qtcreator中Tools-->Options-->Build & Run 找到Debuggers选项卡添加/usr/bin/gdb-multiarch,对应的Kits中使用的gdb换成添加的这个。

剩下的就是开启调试了。假设开发板的IP是192.168.1.123,虚拟机的IP是192.168.1.124。

1.登录到开发板telnet 192.168.1.123,

2.挂载nfs服务器 mount -t nfs  192.168.1.124:/nfsshare /mnt/nfs -o nolock,

3.然后gdbserver 192.168.1.124:8888 /mnt/nfs/yourapp -qws 回车,

4.最后Qtcreator中Debug菜单-->Start Debugging-->Attach to Running Debug Server

在弹出的窗口中kit选择自己配置的嵌入式的,

端口号8888,

Override Server Address:192.168.1.123,

Local executable:可执行文件在虚拟机中的位置

点击OK就可以正常调试了。

  • 1
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值