34

The TestFlight SDK recommends setting Strip Debug Symbols During Copy to YES in Xcode Build Settings to enable the best crash reporting possible. I noticed that it's set to YES by default.

Should I change it to YES? Why or why not?

ma11hew28
  • 121,420
  • 116
  • 450
  • 651
  • 16
    This is incorrect: the TestFlight SDK recommends you set `Strip Debug Symbols During Copy`, among other settings, to `NO`! – codeperson Apr 02 '12 at 00:04

3 Answers3

36

I work at TestFlight. Short answer is: set it to YES.

Long answer:

@Kerni is correct. Before we started symbolicating server side, we needed that data to symbolicate on device.

So if you upload your dSYM to TestFlight, you can strip them. If you don't want to upload your dSYM for some reason, you can leave them in and TestFlight can symbolicate on device.

Basically the README was not updated. Sorry @Manni! I will update it for the next release. (I'm going to remove that entire section).

Sorry about the confusion!

jasongregori
  • 11,451
  • 5
  • 43
  • 41
  • 1
    What if I set it to `NO` for `Debug`? Does it help me with debugging? Does it matter if the local app has a bigger size? It build the app slower? – Iulian Onofrei Sep 07 '15 at 14:36
  • I don't think there is any reason to set it to NO for debug. I don't think it helps anything. The app is bigger so it would be slightly slower to load onto device. – jasongregori Sep 07 '15 at 15:21
  • Why is [this](https://www.cocoanetics.com/2015/04/skipping-copy-phase-strip) saying that you should set it to `NO`? I also tried what he said in `Xcode 6.4` and the project's setting is set to `NO` for a new project. – Iulian Onofrei Sep 08 '15 at 07:34
26

If the default setting is YES, there is no need to do anything else.

In general this setting makes sure that debug symbols are not part of the distributed binary which reduces the file size by 30-50%. The debug symbols should instead be written to the dSYM DWARF file, which can later be used to symbolicate crash reports.

Kerni
  • 15,241
  • 5
  • 36
  • 57
7

The TestFlight SDK recommends to set this setting to NO, not to YES:

To enable the best crash reporting possible we recommend setting the following project build settings in Xcode to NO for all targets that you want to have live crash reporting for. You can find build settings by opening the Project Navigator (default command+1 or command+shift+j) then clicking on the project you are configuring (usually the first selection in the list). From there you can choose to either change the global project settings or settings on an individual project basis. All settings below are in the Deployment Section.

  • Deployment Postrocessing
  • Strip Debug Symbols During Copy
  • Strip Linked Product

Bugsense (http://www.bugsense.com/pages/faq) also recommend this setting with this explanation:

Why do I get memory dumps instead of the stack trace for my iOS app?
iOS apps usually don’t include debugging information or this information is included in a special file with the extension dSYM (debugging SYMbols). To turn on (and include in your binary) debugging information for your iOS app you must set to NO a project setting called “Strip Debug Symbols” for all project configurations.

Manni
  • 11,108
  • 15
  • 49
  • 67
  • 18
    Both tips are bad, since you blow up the app size too much. Also there is no need to add them into the binary, since they can be symbolicated on your Mac. Also HockeyApp, the service I am involved in, provides full server side crash report symbolication without the need of adding the symbols to the binary. Also Testflight changed there recommendation since they allow uploading a dSYM since some time. They probably did not update their FAQ. – Kerni Jan 20 '12 at 13:14