我用brew安装了gdb 8.1.
我有codeign gdb和.gdbinit如下:
set startup-with-shell off.
我已禁用SIP功能:
$ csrutil status
System Integrity Protection status: disabled.
但是gdb仍然不起作用:
#include <iostream>
using namespace std;
int main() {
  cout << "hello world!" << endl;
  return 0;
}
编译命令:
g++ -g test.cpp
gdb输出:
GNU gdb (GDB) 8.1
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted …这是我昨天第一次更新到macOS Sierra时出现的问题.
GDB本身运行正常.但是,不知何故,它无法运行我的程序.当我输入'run'和'enter'时,它会立即崩溃并显示以下信息:
During startup program terminated with signal SIG113, Real-time event 113.
我的GDB基于自制软件.所以今天,我卸载了整个自制程序包并重新安装它.在编码协议步骤之后,我仍然面临同样的错误.
我试过'sudo'和其他一些东西.谷歌不知道发生了什么.所以我想知道你们是否有一些神奇的解决方案.