GDB远程调试-无法实例化默认可视化工具的打印机 [英] GDB Remote Debugging - Cannot instantiate printer for default visualizer

查看:294
本文介绍了GDB远程调试-无法实例化默认可视化工具的打印机的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在eclipse中设置远程gdb调试.调试器将逐步完成代码,但是所有变量都显示以下错误:

Setting up remote gdb debugging in eclipse . The debugger will step through the code just fine but, all of the variables show the following error:

1)无法执行MI命令: -var-create-var_Name来自调试器后端的错误消息:无法实例化默认可视化工具的打印机

1) Failed to execute MI command: -var-create - var_Name Error message from debugger back end: Cannot instantiate printer for default visualizer

基本上,变量中没有显示值. 是否有.gdbinit文件的设置可以解决此问题,或者在eclipse中有其他设置?

Basically, values don't show up for the variables. Is there a setting for the .gdbinit file to fix this, or some other setting in eclipse?

  • 远程设备使用NFS挂载localhost/path/to/app
  • 编译器:gcc-linaro-4.9.4-2017.01-x86_64_arm-linux-gnueabihf
  • 本地主机:运行linux mint 19.2并使用arm-linux-gnueabihf-gdb
  • 远程:gdbserver:port/path/to/app

  • The remote device uses NFS to mount the localhost /path/to/app
  • compiler: gcc-linaro-4.9.4-2017.01-x86_64_arm-linux-gnueabihf
  • localhost: running linux mint 19.2 and using arm-linux-gnueabihf-gdb
  • remote: gdbserver :port /path/to/app

user@localhost:/ gdb --version
GNU gdb (Debian 7.7.1+dfsg-5) 7.7.1

推荐答案

从Eclipse主窗口:窗口->首选项-> C/C ++->调试-> GDB:在漂亮打印"区域下,取消选择在变量中启用漂亮打印机" /表达式树"

From Eclipse Main window: Window -> Preferences -> C/C++ -> Debug -> GDB : Under Pretty Printing region, Deselect "Enable pretty printers in variable/expression tree"

然后单击应用"和应用并关闭",这将在远程调试会话期间立即打印出变量.无需更改.gdbinit文件.

Then click "Apply" and "Apply and Close" viola the variables now print out during remote debug sessions. No change to my .gdbinit file was needed.

也许我没有使用启用了python的GDB ...我不确定.

Perhaps I am not using python-enabled GDB... I am not sure.

这篇关于GDB远程调试-无法实例化默认可视化工具的打印机的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆