eclipse .gdbinit 文件丢失

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/14795407/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-19 19:59:07  来源:igfitidea点击:

.gdbinit file missing

c++eclipsegdbgdbinit

提问by user2058314

Eclipse is not debugging my c++ code. It asked for a version of gdb. I fixed the path of gdb but .gdbinit file is still missing. I cant locate it. The debug process just terminates now. Does eclipse has an inbuilt .gdbinit file whose location i can give? Can someone please give me a standard .gdbinit file?

Eclipse 没有调试我的 C++ 代码。它要求一个版本的gdb。我修复了 gdb 的路径,但 .gdbinit 文件仍然丢失。我找不到它。调试过程现在刚刚终止。eclipse 是否有一个内置的 .gdbinit 文件,我可以提供它的位置?有人可以给我一个标准的 .gdbinit 文件吗?

May be its debugging properly but eclipse is not correctly parsing gdb output. Is there a plugin to fix this?

可能是它的调试正常,但 eclipse 没有正确解析 gdb 输出。有没有插件可以解决这个问题?

I would greatly appreciate the help. Thanks

我将不胜感激。谢谢

回答by mkfs

It is difficult to tell if a) you are having trouble getting Eclipse to find your existing .gdbinit file, or b) you are missing a .gdbinit file.

很难判断是 a) 您在让 Eclipse 找到现有的 .gdbinit 文件时遇到问题,还是 b) 缺少 .gdbinit 文件。

a) On UNIX and Linux systems, the path to the gdb init file is ~/.gdbinit (or $HOME/.gdbinit) - that is, the .gdbinit file is at the top level of your home directory.

a) 在 UNIX 和 Linux 系统上,gdb init 文件的路径是 ~/.gdbinit(或 $HOME/.gdbinit)——也就是说,.gdbinit 文件位于主目录的顶层。

b) A .gdbinit file is not required to run gdb -- even an empty file named .gdbinit will do. For example .gdb init files, check dotfiles.org.

b) 运行 gdb 不需要 .gdbinit 文件——即使是一个名为 .gdbinit 的空文件也可以。例如 .gdb init 文件,检查dotfiles.org