“Message from debugger: Terminated due to code signing error” when debugging a Mac app?

最后都变了- 提交于 2019-12-22 10:35:13

问题


I'm writing a Mac app in the sandbox, and can't seem to get code signing to work. I've selected "Developer ID" from the Info tab for my target, and I've tried letting Xcode set up my provisioning profile automatically as well as creating the profile myself. The app builds without any errors or warnings, but when I try to "build and run," it gives me the following error:


回答1:


In console.app, I noticed I was getting the following message:

3/5/15 4:46:37.151 PM taskgated[73]: killed com.nateparrott.Boxcar[pid 27408] because its use of the com.apple.developer.ubiquity-container-identifiers entitlement is not allowed (error code -67050)

It turns out that the default entitlements file in my project included an empty list of iCloud container, which caused the sandbox to think the app needed iCloud permissions (which weren't included in the default provisioning profile). Removing the iCloud entry from the entitlements file solved the problem.




回答2:


Try to regenerate your certificates from the Dev Center. This happens most of the times when you switch to a new mac or after upgrading to a newer OS X version.




回答3:


  • You have downloaded and installed your cert (in Keychain Access) from the portal. If you created the cert today on the same Mac you're trying to run it on this won't be your issue.
  • Your cert from above is in the provisioning profile you imported into XCode.
  • You actually imported your provisioning profile into XCode. It should be selectable form your Build Settings drop-down.
  • The bundle identifier you created in the portal matches what you have designated in your project under the Target Info.



回答4:


I tried Setting Build Settings->code signing identity to "Mac Developer" and Provisioning Profile to "Automatic". The debugger worked fine after that.



来源:https://stackoverflow.com/questions/28803510/message-from-debugger-terminated-due-to-code-signing-error-when-debugging-a-m

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!