简体   繁体   English

如何将嵌入式框架的dSYM文件包含到应用程序存档中

[英]How to include dSYM file of an embedded framework to an app archive

My app uses some 3rd party framework. 我的应用使用了一些第三方框架。 I have a framework itself and dSYM file for it. 我有一个框架本身和dSYM文件。

When archiving my app, the archive does not contain the dSYM file for this framework. 归档我的应用程序时,归档文件不包含此框架的dSYM文件。 It contains other dSYM files for ther frameworks that're included via Cocoa Pods and built alongside with my app. 它包含其他dSYM文件,用于通过Cocoa Pod包含的框架,并与我的应用程序一起构建。

I'm using HockeyApp for app distribution, so I'm uploading my app IPA and dSYMs archive to it. 我正在使用HockeyApp进行应用分发,所以我将我的应用IPA和dSYMs存档上传到它。 But because of lacking of this exact dSYM for this exact framework, I can't see all stack trace in crash reports. 但由于缺乏这个确切框架的精确dSYM,我无法在崩溃报告中看到所有堆栈跟踪。

So The question: How can I kindly ask Xcode to copy dSYM file for the framework? 所以问题:我怎么能请Xcode复制框架的dSYM文件? Should I do this manually via script during archiving? 我应该在归档期间通过脚本手动执行此操作吗?

If you have pre-built frameworks you need to add the dSYM files generated at build time to your Xcode project and add a new "Copy Files Phase" to your target's Build phases in order to end up with them in the Xcode archive. 如果您有预构建的框架,则需要将构建时生成的dSYM文件添加到Xcode项目中,并将新的“复制文件阶段”添加到目标的构建阶段,以便最终在Xcode存档中使用它们。

An example of adding the dSYM files for the Realm framework would look like the screenshot below. 为Realm框架添加dSYM文件的示例如下面的屏幕截图所示。

Make sure you select the "Products Directory" destination and the "Copy only when installing" option. 确保选择“产品目录”目标和“安装时仅复制”选项。

复制文件阶段

Now, when archiving your target the dSYMS will appear in the right directory. 现在,归档目标时,dSYMS将显示在正确的目录中。

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

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