(gdb) run
Starting program: /Users/lurongming/test/cpptest/main
Unable to find Mach task port for process-id 33242: (os/kern) failure (0x5).
(please check gdb is codesigned - see taskgated(8))

mac 下使用gdb调试出现问题。

https://opensource.apple.com/source/lldb/lldb-69/docs/code-signing.txt

打开启动台>>其他>>钥匙串访问>>证书助理>>创建证书:

创建证书:

一直继续。证书的位置需要为系统。

会提示你输入密码:

创建完毕后可以看到,钥匙串选择系统,种类选择我的证书:

打开显示简介:

选择始终信任:

然后打开终端,输入:

:sudo killall taskgated
:codesign -fs gdb_codesign gdb
gdb: No such file or directory
1
2
3
报错,查找gdb:

:which gdb
/usr/local/bin/gdb
1
2
然后执行:

:codesign -fs gdb_codesign /usr/local/bin/gdb
1
此时会要求你输入密码:

Unable to find Mach task port for process-id : (os/kern) failure (0x5). (please check gdb is codesi的更多相关文章

  1. 进程ID[PID(Process ID)]与端口号[(Port ID)]的联系

    1.首先声明一点:PID不是端口(port id),而是Process ID进程号的意思. 2.那么,什么是进程号? 采集网友的意见就是: 进程号,是系统分配给么一个进程的唯一标识符.PID就是各进程 ...

  2. selenium+phantomjs报错:Unable to find a free port的分析和解决

    selenium+phantomjs报错:Unable to find a free port的分析和解决 Table of Contents 1. 现象 2. 分析 3. 解决办法 1 现象 在做项 ...

  3. Unable to load tag handler class "com.showId.Id.ShowId" for tag "ShowId:ShowId"] with root cause错误的解决方案

     严重: Servlet.service() for servlet [jsp] in context with path [/Biaoqian] threw exception [/1.jsp (l ...

  4. Transaction (Process ID xxx) was deadlocked on lock

    Transaction (Process ID 161) was deadlocked on lock | communication buffer resources with another pr ...

  5. 多线程处理sql server2008出现Transaction (Process ID) was deadlocked on lock resources with another process and has been chose问题

    多线程处理sql server2008某个表中的数据时,在Update记录的时候出现了[Transaction (Process ID 146) was deadlocked on lock reso ...

  6. java代码中获取进程process id(转)

    另一方面,线程ID=进程ID+内部线程对象ID并不成立,    参考: blog.csdn.net/heyetina/article/details/6633901     如何在java代码中获取进 ...

  7. A discussion of Dead Connection Detection, Resource Limits, V$SESSION, V$PROCESS and OS processes

    A discussion of Dead Connection Detection, Resource Limits, V$SESSION, V$PROCESS and OS processes (文 ...

  8. check process id exists

    kill -0 pid sending the signal 0 to a given PID just checks if any process with the given PID is run ...

  9. Process ID, Process handle, Window handle

    http://forums.codeguru.com/showthread.php?392273-RESOLVED-How-to-get-window-s-HWND-from-it-s-process ...

  10. 查看进程id, 父进程id _How do I get the parent process ID of a given child process?

    How to get parent pid from a given children pid? I know I can mannully check it under /proc, I am wo ...

随机推荐

  1. CF753B题解

    这应该算是一个很脍炙人口的小游戏了吧 (没玩过算我没说) 因为一共有 \(50\) 次询问机会,那最简单直接的方法就不难想到. 我们把 \(0 \sim9\) 全部询问一遍,如果回答两个整数不全为 \ ...

  2. 00 通过 Pytorch 实现 Transformer 框架完整代码

    博客配套视频链接: https://space.bilibili.com/383551518?spm_id_from=333.1007.0.0 b 站直接看 配套 github 链接:https:// ...

  3. Python 潮流周刊#72:Python 3.13.0 最终版已发布!(摘要)

    本周刊由 Python猫 出品,精心筛选国内外的 250+ 信息源,为你挑选最值得分享的文章.教程.开源项目.软件工具.播客和视频.热门话题等内容.愿景:帮助所有读者精进 Python 技术,并增长职 ...

  4. HDU-ACM 2024 Day2

    T1004 a*b problem(HDU 7448) 不会. T1005 小塔的养成游戏之梦(HDU 7449) 不会. T1009 强攻计策(HDU 7453) 容易发现初始速度是多少对答案没有影 ...

  5. Win11使用Translucent TB设置Windows导航栏透明失败解决方案

    Win11使用Translucent TB设置Windows导航栏透明失败解决方案 Translucent TB下载方式:直接在Windows自带的Microsoft应用商店里面搜索下载就可以了 1. ...

  6. node.js安装及环境配置基于Windows系统

    node.js安装及环境配置-Windows系统 1. 下载安装包 https://nodejs.org/zh-cn/download/ 根据自己电脑系统及位数选择,我的电脑是Windows系统.64 ...

  7. Selenium实现元素定位

    Selenium提供了定位元素的方法find_element(),该方法被定义在WebDriver类中. 一.参数 1.两个参数,参数1根据不同定位方法确定,定位方法如下: (1)通过id定位:使用参 ...

  8. ClickHouse-查询优化

    单表查询[使用的频率高] 1.prewhere代表where Prewhere 和 where 语句的作用相同,用来过滤数据.不同之处在于 prewhere 只支持*MergeTree 族系列引擎的表 ...

  9. 模拟器(Nintendo,Genesis,SFC,MD,土星,PS,PS2,PS3,Wii,Xbox等)游戏下载网址

    最近想拿个英文游戏复习复习,国内的emu618关闭之后难得寻到很完整的游戏库 通过 https://www.fantasyanime.com/mana/som2downloads.htm 找到 htt ...

  10. 开源 - Ideal库 - 枚举扩展设计思路及实现难点(三)

    今天想和大家分享关于枚举扩展设计思路和在实现过程中遇到的难点. 01.设计思路 设计思路说起来其实也很简单,就是通过枚举相关信息:枚举值.枚举名.枚举描述.枚举项.枚举类型,进行各种转换,通过一个信息 ...