简体   繁体   English

Xcode位码,“包含符号”设置对dSYM生成有影响

[英]Xcode Bitcode, Include Symbols settings effect on dSYM generation

Since I use Crashlytics to handle my crashes, I always uncheck the “Include app symbols for your application to receive symbolicated crash logs from Apple” and keep the "Include Bitcode" one checked (future proof for Apple Watch) before submitting my app to iTunes Connect like this : 由于我使用Crashlytics来处理崩溃,因此,在将我的应用程序提交到iTunes之前,我总是取消选中“为您的应用程序包含应用程序符号以从Apple接收带符号的崩溃日志”,并始终选中“包括位码 (Apple Watch的未来证明)。像这样连接:

设定值

Crashlytics has an article about issue with Bitcode and missing dSYMs : Crashlytics有一篇有关位码问题和缺少dSYM的文章:

https://docs.fabric.io/apple/crashlytics/missing-dsyms.html#bitcode-download https://docs.fabric.io/apple/crashlytics/missing-dsyms.html#bitcode-download

According to their screenshot, to download the new generated dSYM file created by Bitcode, there is a download link available directly in iTunes Connect, BUT, it seems that you must have checked "Include app symbols" to be able to download them, otherwise you simply get this: 根据他们的屏幕截图,要下载由Bitcode创建的新生成的dSYM文件,iTunes Connect,BUT中直接存在一个下载链接,看来您必须选中“包括应用程序符号”才能下载它们,否则,简单地得到这个:

没有

So I'm a bit confused on how these two settings are required for the well-functioning of Crashlytics or any 3rd party crashes handler service. 因此,对于Crashlytics或任何第三方崩溃处理程序服务的正常运行如何需要这两个设置,我有些困惑。

Should I keep both settings checked? 我应该同时检查两个设置吗? Is it OK to uncheck "Include app Symbols" since I don't use Apple's Crash organizer (from my understanding, dSYM files are uploaded to Crashlytics during their post-script archive) and only keep Bitcode checked or if I do that I won't be able to download new Bitcode generated dSYMs (causing problems to Crashlytics symbolize crashes correctly)? 是否可以取消选中“包括应用程序符号”,因为我不使用Apple的Crash组织者(据我了解,dSYM文件在其后脚本存档期间上传到Crashlytics),并且仅保持对位码的检查,或者如果我这样做,我会否?不能下载新的由Bitcode生成的dSYM(导致Crashlytics问题正确地表示崩溃)?

This is a good question. 这是一个很好的问题。 There are numerous knobs that affect the availability of debug symbol information for your app. 有许多旋钮会影响应用程序的调试符号信息的可用性。 It's confusing, and people are constantly tripped up by it. 这令人困惑,人们不断被它绊倒。

Here are my guidelines: 这是我的指南:

  • always check the "include symbols" box when submitting apps to Apple 向苹果提交应用程序时,请务必选中“包含符号”框
  • always strip your final executables (.app, .framework) 始终剥离最终的可执行文件 (.app,.framework)
  • never strip your static libraries, if you have any 如果有的话,切勿剥离静态库
  • you want Apple's crash reporting to work, even if you don't plan to look at it 即使您不打算查看,也希望Apple的崩溃报告能够正常工作

With this configuration, your dSYMs, produced locally or by Apple, will contain the debug information necessary for both Crashlytics and Apple's reporter to work. 使用此配置,本地或Apple生产的dSYM将包含Crashlytics和Apple的报告程序正常工作所必需的调试信息。 It is critical you share symbols with Apple when using bitcode. 这是您在使用时,位码与苹果共享符号的关键 If you do not, it is likely you will never be able to see symbolicated crashes for that version of your app. 如果您不这样做,则很可能您将永远无法看到该应用程序版本的象征性崩溃。

There are, of course, some valid reasons why you might not want to share symbols with Apple. 当然,有一些正当的理由为什么您可能不想与Apple共享符号。 One is you want to obfuscate your code. 一种是您希望混淆代码。 I'm aware of a few apps that do this. 我知道一些这样做的应用程序。 Of course, this is a trade-off, because it makes symbolication much harder, or even impossible, depending on the obfuscation system. 当然,这是一个折衷方案,因为根据混淆系统,它会使象征变得更加困难,甚至变得不可能。

There are also reasons why you might not want to strip your executables. 还有一些原因可能导致您不希望剥离可执行文件的原因。 One is that you rely on a 3rd party crash reporting system that does not support server-side symbolication. 一种是您依赖不支持服务器端符号化的第三方崩溃报告系统。 This is less and less common, as far as I know, but it is something to be aware of. 据我所知,这种情况越来越少,但这是需要注意的事情。

Finally, you definitely do want Apple's crash reporting system to work, even if you never plan on using it. 最后,即使您从未计划使用它,您肯定也希望Apple的崩溃报告系统能够运行。 Apple's system is able to capture more crashes more reliably than any 3rd-party solution could. 苹果的系统比任何第三方解决方案都能够更可靠地捕获更多的崩溃。 I'm sure it is also invaluable for Apple's internal work. 我敢肯定,这对于苹果公司的内部工作也是无价的。 It definitely does have limitations, but really doesn't cost you anything. 它确实有局限性,但实际上并不会花费您任何费用。 So, keep it working, if for no other reason than to have the option to look at it in the future. 因此,如果没有其他原因可以选择继续进行下去,请使其继续运行。

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

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