Goland ssh调试模式失败:可执行文件不包含调试信息。

huangapple go评论125阅读模式
英文:

Goland ssh debug mode fail: executable doesn't containt debug information

问题

我使用Goland ssh编写代码。我在项目中无法使用调试模式,断点变成了灰色的交叉圆圈,并报错“可执行文件不包含调试信息”。
错误信息在这里。

这是我的项目的运行/调试配置。

然而,我仍然可以在测试文件中使用调试模式和设置正常的断点。

英文:

I use Goland ssh to write code. I fail to use debug mode in my project, the breakpoints turn into gray crossed circles and report error "executable doesn't containt debug information".
The error information is here.

This is the Run/Debug Configuration of my project

However, I still could use debug mode and set normal breakpoints in Testing file.

答案1

得分: 1

我刚刚遇到了完全相同的问题。

最后我发现问题是我设置断点的函数在仓库中没有被调用。

它是由另一个仓库调用的,所以编译和调试调用这个函数的仓库可以解决这个问题。

错误信息“错误层=调试器错误加载二进制文件“/lib/x86_64-linux-gnu/libpthread.so.0”:无法解析.eh_frame部分:不支持指针编码0x9b at 0x12e8”仍然存在,但断点不会变成灰色的交叉圆圈。

英文:

I met exactly the same problem just now.

Finally I find the reason is the function which I set breakpoint doesn't been called in the repo.

It's called by another repo, so compile and debug the repo that call this function can solve this problem.

The error "error layer=debugger error loading binary "/lib/x86_64-linux-gnu/libpthread.so.0": could not parse .eh_frame section: pointer encoding not supported 0x9b at 0x12e8" still exists, but the breakpoints won't turn into gray crossed circles.

答案2

得分: 0

请查看此链接:https://youtrack.jetbrains.com/issue/GO-13005。
下一个2022.2的夜间构建捆绑了delve,不会产生错误。

英文:

please see this https://youtrack.jetbrains.com/issue/GO-13005 .
Next 2022.2 nightly build bundles delve which doesn't produce an error.

huangapple
  • 本文由 发表于 2022年5月23日 23:44:48
  • 转载请务必保留本文链接:https://go.coder-hub.com/72351361.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定