简体   繁体   English

为什么应用归档在 iOS、swift、xcode 9.2 中使用自定义框架失败

[英]Why app archive failed with custom frameworks in iOS, swift, xcode 9.2

I'm creating an iOS app which use my own custom framework .我正在创建一个使用我自己的自定义框架iOS 应用程序 Can build, run with real iOS devices & with simulators .可以在真实的iOS 设备模拟器上build, run

But if I try to Archive the project for App Store it gives me Error says :但是,如果我尝试为App Store存档项目,它会给我错误说:

 the functions & classes are unresolved identifier

I have used so many third party frameworks (not the cocoa pods) (ex: facebook or any) and can user properly from build, run to archive.我使用了很多第三方框架(不是可可豆荚)(例如:facebook 或任何),并且可以从构建、运行到存档正确地使用。 But why can't we use our own framework for archive .但是为什么我们不能使用我们自己的archive framework

NOTE: just drag and drop my custom framework to my iOS project and selected copy items if needed.注意:只需将我的自定义框架拖放到我的 iOS 项目中,并根据需要选择复制项目。

Any reason for this and how can I overcome this problem.任何原因以及我如何克服这个问题。

I found a way to do this.我找到了一种方法来做到这一点。 but there may be other ways as well.但也可能有其他方式。 this is open to any answer .这对任何答案都是开放的

I followed below steps :我遵循以下步骤:

  • In your custom framework project ( cocoa touch framework project ) , select your Project in Targets .在您的自定义框架项目(cocoa touch 框架项目)中,在Targets 中选择您的项目
  • Then search for Skip install .然后搜索Skip install
  • Change it into NO .将其更改为NO
  • Then archive your custom framework.然后归档您的自定义框架。 ( make sure to select Generic iOS Device ) as target device. (确保选择Generic iOS Device )作为目标设备。
  • Export it to where you want.将其导出到您想要的位置。
  • Then use it with your project.然后在您的项目中使用它。

Hope this will help to you希望这对你有帮助

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM