无法解决错误:可执行文件已在 xcode 4.2 中使用无效的调试权利签名
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/8113327/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Can't Resolve Error: The executable was signed with invalid entitlements for Debug in xcode 4.2
提问by JeffB6688
I am trying to build for debugging. I am getting the error: The executable was signed with invalid entitlements. The entitlements specified in your application's Code Signing Entitlements file do not match those specified in your provisioning profile.
我正在尝试构建以进行调试。我收到错误消息:可执行文件的签名无效。在您的应用程序的代码签名权利文件中指定的权利与在您的配置文件中指定的权利不匹配。
This worked every day until last night. The last time it worked was when I clicked on Always Allow on the codesign question that pops up when you build where it says it wants to sign using key "my key name" in your keychain.
这每天都有效,直到昨晚。上一次它起作用是当我在构建时弹出的协同设计问题上单击“始终允许”时,它说它想使用钥匙串中的“我的密钥名称”进行签名。
I have an entitlements plist already that I used for creating my ad hoc distribution. I have updated build settings for Code Signing Entitlements for Debug to include this Entitlements.plist file.
我已经有一个权利 plist,用于创建我的临时分发。我已经更新了调试代码签名权利的构建设置以包含此 Entitlements.plist 文件。
I have verified that my profiles are up to date. My Team Provisioning Profile had expired, so I renewed it. I even tried creating new profiles. Still didn't help
我已经确认我的个人资料是最新的。我的团队配置文件已过期,所以我更新了它。我什至尝试创建新的配置文件。仍然没有帮助
I have tried both my developer profile and my distribution profile in the build settings under Code Signing Identity for Debug.
我已经在 Code Signing Identity for Debug 下的构建设置中尝试了我的开发人员配置文件和我的分发配置文件。
I am completely stuck. Can anyone give me new advice?
我完全被困住了。谁能给我新的建议?
回答by JeffB6688
I finally got this to work.
我终于得到了这个工作。
1) In the left column of xcode, I clicked on my project name.
1)在xcode的左栏中,我点击了我的项目名称。
2) I clicked on Build Settings
2)我点击了构建设置
3) There are 4 columns: Resolved, myProjectName (with an orange icon), myProjectName (with an xcode icon), and IOS Default.
3) 有 4 列:Resolved、myProjectName(带有橙色图标)、myProjectName(带有 xcode 图标)和 IOS Default。
4) In the column with the orange icon and the row for Code Signing Entitlements (Debug row), I removed the Entitlements.plist file name from that column, but left it in the column with the xcode icon.
4) 在带有橙色图标的列和代码签名权利行(调试行)中,我从该列中删除了 Entitlements.plist 文件名,但将其保留在带有 xcode 图标的列中。
5) In the row for Code Signing Identity (Debug), I chose iPhone Developer in both the column with the orange icon and the xcode icon. I used the Automatic Profile selector.
5) 在 Code Signing Identity (Debug) 行中,我在带有橙色图标和 xcode 图标的列中都选择了 iPhone Developer。我使用了自动配置文件选择器。
This fixed my problem. Please not the other things I did in my question as these may also have had an impact.
这解决了我的问题。请不要我在问题中做的其他事情,因为这些也可能产生了影响。
回答by Darren
This message can come up when there's a problem with the provisioning profile. I got this message when I tried running on a device that did not have the latest provisioning profile. I simply reloaded the provisioning profile from the Developer portal, then made sure the Debug/Release signing used the latest version. Then it ran fine.
当供应配置文件出现问题时,可能会出现此消息。当我尝试在没有最新配置文件的设备上运行时收到此消息。我只是从开发人员门户重新加载了配置文件,然后确保调试/发布签名使用了最新版本。然后它运行良好。