GDB kind of doesn't work on macOS Sierra

前端 未结 8 767
梦毁少年i
梦毁少年i 2020-12-02 07:55

It is a problem that appeared when I first updated to macOS Sierra yesterday.

GDB itself is running OK. However, somehow, it cannot run my program. When I type \'run

8条回答
  •  悲&欢浪女
    2020-12-02 08:10

    I know my answer is not specifically related to GDB, but since I also had some difficulties making GDB to work myself, I'd like to recommend you to give a try on LLDB. For me, it worked like a charm:

    https://developer.apple.com/library/content/documentation/IDEs/Conceptual/gdb_to_lldb_transition_guide/document/lldb-terminal-workflow-tutorial.html

    Since Xcode itself now uses LLDB instead of GDB, this can be a more convenient alternative for Mac users. And, in my particular case, it integrated much easier in Eclipse than GDB:

    https://wiki.eclipse.org/CDT/User/FAQ#How_do_I_get_the_LLDB_debugger.3F

提交回复
热议问题