我收到一条错误提示
<块引用>链接到在应用程序扩展中使用不安全的 dylib
我查看了解决此问题的其他问题,唯一有答案的问题没有解决我的问题,其余的根本没有得到任何答案.
我尝试构建一个根本没有任何内容的框架,并将该框架添加到我的意图应用扩展的常规选项卡中的链接框架和库中,但我仍然收到此消息.
当我向框架添加代码时,我仍然收到警告消息.
这是我的代码:
导入 UIKit类小部件:NSObject {}
我一定会按照
I am receiving an error that says
linking against a dylib which is not safe for use in application extensions
I have looked at the other questions that address this, the only one that had answers did not solve my problem, and the rest had received no answers at all.
I tried just building a framework with nothing in it at all, and adding the framework to Linked Frameworks and Libraries in the General tab of my intents app extension, and I still get this message.
When I add code to the framework, I still get the warning message.
Here is my code:
import UIKit
class Widget: NSObject {
}
I am sure to follow instructions at Some APIs Are Unavailable to App Extensions and at Using an Embedded Framework to Share Code but I still get the same warning message. I have read that Apple App Store will not pass my app for review if I have this issue.
If you are linking against a framework you control, select the framework target in your project. In the General tab, look at Deployment Info and you will see a line:
App Extensions: [ ] Allow app extension API only
Select the checkbox, and you should be able to link against this framework.
This checkbox ensures that only calls to APIs that are valid within App Extensions are used.
这篇关于链接到在应用程序扩展中使用不安全的 dylib 的警告消息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!