open /Applications/Utilities/Keychain\ Access.app/

打开 钥匙串访问

Mac 创建证书(以 创建gdb证书 为例  )

Mac 创建证书(以 创建gdb证书 为例  )

Mac 创建证书(以 创建gdb证书 为例  )

Mac 创建证书(以 创建gdb证书 为例  )

继续继续

Mac 创建证书(以 创建gdb证书 为例  )

Mac 创建证书(以 创建gdb证书 为例  )

Mac 创建证书(以 创建gdb证书 为例  )

Mac 创建证书(以 创建gdb证书 为例  )

 创建完毕。

Now that we have a certificate, we need to use it to sign GDB. First, we'll restart the taskgatedprocess to make sure it picks up the new certificate. Quit Keychain Access (you must quit Keychain Access!) and return to the Terminal for these final commands.

Find the taskgated process.

ps -e grep taskgated
Mac 创建证书(以 创建gdb证书 为例  )
 

The first number in the above output is the PID. Use this to kill the process (it will immediately restart itself). 我 kill 掉 taskgated 之后,它没有自动重启,所以建议创建完证书之后,重启下系统,然后再执行:codesign -s gdb-cert $(which gdb)

Now you can finally code sign GDB.

# Homebrew version
$ codesign -s gdb-cert $(which gdb)
  Mac 创建证书(以 创建gdb证书 为例  )

Now you should be all set! The OS X Keychain may ask for your password the first time you attempt to debug a program, but it should work!

 

相关文章:

  • 2022-12-23
  • 2021-06-27
  • 2022-02-22
  • 2021-08-24
  • 2021-07-29
  • 2022-12-23
  • 2021-11-07
  • 2021-09-26
猜你喜欢
  • 2021-12-15
  • 2021-06-12
  • 2021-09-16
  • 2022-12-23
  • 2022-02-26
  • 2021-11-15
相关资源
相似解决方案