我需要迦太基创建的bcsymbolmap文件吗 [英] Do I need bcsymbolmap files created by Carthage

查看:87
本文介绍了我需要迦太基创建的bcsymbolmap文件吗的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在我的iOS项目中使用了迦太基依赖性管理器.我的存储库中有 Carthage/build 文件夹,可以在签出存储库时随时准备使用内置框架.

I am using Carthage dependency manager in my iOS project. I have the Carthage/build folder in my repository to always have ready to go built frameworks when checking out the repo.

我想知道构建文件夹中的 bcsymbolmap 文件是干什么用的.每次 carthage更新都会创建其中的很多.

I am wondering what the bcsymbolmap files in the build folder are for. Quite a few of them are created with every carthage update.

我需要保留这些文件吗?我应该在存储库中保存它们吗?

Do I need to keep these files? Should I have them in my repository?

推荐答案

否,您不需要这些文件.如果正确设置了迦太基,则将在构建阶段复制二进制,.dsym和.bcsymbolmap文件.当您存档构建以使用App Store分发时,所有需要的文件都将包含在存档中,并且在将构建上传到App Store之后,您将能够随时上传dsyms文件(以便能够对崩溃报告进行解码).如果确实如此,则不需要在存储库中存储.dsyms和.bcsymbolmap文件.

No, you don't need those files. If you set up Carthage properly, binary, .dsym and .bcsymbolmap files will be copied on build phase. When you archive the build for distributing using App Store, all needed files will be included in archive and after you upload the build to App Store you will be able to upload dsyms files anytime (to be able to decode your crash reports). If fact you don't need to store .dsyms and .bcsymbolmap files in your repository.

有一篇很好的文章解释了在构建框架时发生了什么(以及实际上迦太基脚本所做的事情) https://instabug.com/blog/ios-binary-framework/.它还说明了.bcsymbolmaps文件的用途-苹果服务器可以使用Bitcode重建代码,然后可以对崩溃报告进行解符号化.

There is a good article explaining what is happening when the framework is being build (and what in fact Carthage scripts do) https://instabug.com/blog/ios-binary-framework/. Also it explains what for .bcsymbolmaps files used for - so Apple servers can rebuild your code using Bitcode and then you can desymbolicate your crash reports.

因此,您不需要保留这些文件.无需将它们存储在存储库中.不存储Build文件夹内容的另一个原因是,无论如何,您的项目可能无法在具有不同环境的另一台计算机上使用它进行构建.如果要使用相同版本的依赖项构建项目,请使用Carthage bootstrap 命令而不是 update .

So, you don't need to keep those files. No need to store them in repository. The other reason not to store content of Build folder is that anyway your project can fail build with it on another machine with different environment. If you want to build your project with the same versions of dependencies - use Carthage bootstrap command instead of update.

P.S.您还可以研究 copy-frameworks 命令的作用:> https://github.com/Carthage/Carthage/blob/fc0166b4827736bac2c804f/Source/carthage/CopyFrameworks.swift

P.S. Also you can investigate what copy-frameworks command do: https://github.com/Carthage/Carthage/blob/fc0166b4827736bac2c804fc928797f1a742c455/Source/carthage/CopyFrameworks.swift

这篇关于我需要迦太基创建的bcsymbolmap文件吗的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆