xcode 缺少权利文件
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/34175353/
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
Missing entitlements file
提问by KexAri
I'm suddenly getting two warnings in XCODE:
我突然在 XCODE 中收到两个警告:
/Users/me/Documents/Misc IOS DEV/myAPP/myAPP.xcodeproj Missing entitlements file for target myAPPUITests: "/var/folders/wb/9dsv1b5j53n8qbwmbh49qf9m0000gn/T/Entitlements.plist-gmk"
/Users/me/Documents/Misc IOS DEV/myAPP/myAPP.xcodeproj Missing entitlements file for target myAPPUITests: "/var/folders/wb/9dsv1b5j53n8qbwmbh49qf9m0000gn/T/Entitlements.plist-pCm"
Anyone have any idea what these are and how I can remove the warnings? Thanks!
任何人都知道这些是什么以及如何删除警告?谢谢!
回答by Ahmad Labeeb
回答by Jordan Smith
Restarting Xcode fixed the issue for me.
重新启动 Xcode 为我解决了这个问题。
The folder those warnings reference is a per-user temporary file/folder cache. If restarting Xcode doesn't fix the issue, I'd suggest restarting OSX.
这些警告引用的文件夹是每个用户的临时文件/文件夹缓存。如果重新启动 Xcode 不能解决问题,我建议重新启动 OSX。
回答by Gabe12
Product > Clean has worked for me multiple times.
产品 > 清洁对我有用过多次。
回答by AWebster
By assigning your Apple Developer ID to the Code Signing Identitysection of the Build settings, this should clear up the warning messages.
通过将您的 Apple Developer ID 分配给Build 设置的Code Signing Identity部分,这应该会清除警告消息。
回答by ZeroOne
Go to Project> Target > Build Settings > Signing
转到项目>目标>构建设置>签名
Here in 'CODE_SIGN_ENTITLEMENTS', put your path.
在“CODE_SIGN_ENTITLEMENTS”中,输入您的路径。
$(SRCROOT)/ProjectName/PathToFolder/AnotherFolder/YourProject.entitlements
$(SRCROOT)/ProjectName/PathToFolder/AnotherFolder/YourProject.entitlements
回答by Ansyar Hafid
Click on your Project Targets, select Capabilities tab, and look for an issue on one of the enabled item. Click on the fix button. Another way to do this also by going to the Build Settings, search for Code Signing Entitlements, make sure it shows "yourProjectModule/EntitlementName.entitlements"
单击您的项目目标,选择功能选项卡,然后查找已启用项目之一的问题。单击修复按钮。另一种方法是转到构建设置,搜索代码签名权利,确保它显示“yourProjectModule/EntitlementName.entitlements”
回答by Ansyar Hafid
Depending on what you want, you can opt to not sign your software (for e.g. local builds, simply playing around).
根据您的需要,您可以选择不对您的软件进行签名(例如,本地构建,只是随便玩玩)。
Select your project in the tree view (item at the top), then in the main window, select "Build Settings", navigate to the section "Code Signing", which is where the error occurs ("code signing entitlements"). Then, for "Code Signing Entity", simply select "Don't Code Sign".
在树视图中选择您的项目(顶部的项目),然后在主窗口中选择“构建设置”,导航到“代码签名”部分,这是发生错误的地方(“代码签名权利”)。然后,对于“代码签名实体”,只需选择“不要代码签名”。
Just remember to update this when you do need to sign your app.
请记住在您确实需要签署您的应用程序时更新它。
回答by Al.
In case anyone finds this, the same happened to me with a new OSX project in the XCode 7.2.
如果有人发现了这一点,我在 XCode 7.2 中的新 OSX 项目中也会发生同样的情况。
In my case, I needed to add my device to my Developer account at https://developer.apple.com, and also create Provisioning Profile for the app.
就我而言,我需要将我的设备添加到https://developer.apple.com 上的开发者帐户,并为应用程序创建配置文件。
I added my device by hand using the UUID from the 'Identifier' value in XCode's Devices Window.
我使用 XCode 设备窗口中“标识符”值中的 UUID 手动添加了我的设备。
I let XCode create the Provisioning Profile, by using the Organizer Window, selecting my App, and then clicking the 'Export ...' button and choosing 'Export a Development-signed Application'.
我让 XCode 创建配置文件,方法是使用管理器窗口,选择我的应用程序,然后单击“导出...”按钮并选择“导出开发签名的应用程序”。
That cleared up the errors on the next build.
这清除了下一次构建的错误。