【问题标题】:GDB 7.11 start errorGDB 7.11 启动错误
【发布时间】:2016-04-15 17:21:14
【问题描述】:

我已经通过 pkg install gdb-7.11 ... 安装了 gdb 7.11 当我尝试运行它时,gdb 给了我这个错误;

i386fbsd-kern.c:482: internal-error: _initialize_i386_kgdb_tdep: Assertion `offsetof(struct pcb, pcb_ebx) == i386fbsd_pcb_offset[I386_EBX_REGNUM]' failed.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Quit this debugging session? (y or n) [answered Y; input not from terminal]

This is a bug, please report it.  For instructions, see:
<http://www.gnu.org/software/gdb/bugs/>.

i386fbsd-kern.c:482: internal-error: _initialize_i386_kgdb_tdep: Assertion `offsetof(struct pcb, pcb_ebx) == i386fbsd_pcb_offset[I386_EBX_REGNUM]' failed.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Create a core file of GDB? (y or n) [answered Y; input not from terminal]
Abort (core dumped)

我无法调试我的核心文件,因为我使用的是 g++ 4.9 编译器,所以我应该使用 7.11...

我的系统:FreeBSD local.com 9.2-RELEASE FreeBSD 9.2-RELEASE #0 r255898: Fri Sep 27 03:52:52 UTC 2013 root@bake.isc.freebsd.org:/usr/obj/usr/src/系统/通用 i386

提前致谢。

【问题讨论】:

  • 我已经安装了全新的 freebsd 10.3 x86 并安装了 gdb 7.11,但仍然是同样的错误!很奇怪。
  • 我在 x86(32 位)上重现了这个错误。从源代码构建 (/usr/ports/devel/gdb) 会生成一个工作版本。
  • 是的,谢谢,当我从端口复制时,它成功了,这很奇怪......

标签: c++ gdb freebsd


【解决方案1】:

乍一看,这看起来像是一个 ABI 问题,但它更像是 GDB 正在做一些非常愚蠢的事情:它尝试将内核后端用于它不知道的内核版本,即使它不需要后端根本 - 因为您正在调试用户空间,而不是内核。

您应该就此提交 PR (http://bugs.freebsd.org)。

【讨论】:

    猜你喜欢
    • 2016-02-25
    • 1970-01-01
    • 2023-01-01
    • 2015-10-12
    • 2016-11-30
    • 2011-01-10
    • 2015-12-21
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多