Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why are static library symbols not included in dSYM during archive?

We have a pretty major application suite for a client with a couple application targets utilizing several static libraries that we made in house. All targets are contained in one XCode project file.

For some reason when archiving an application the dSYM file does not contain any debug symbols for static libraries. The result is when trying to symbolicate crash logs from field agents we cannot see what is going on inside those static libraries.

I attempted to create a new simple XCode project with one application target and one static library. Even then the debug symbols were missing. I fiddled with the build settings according to this https://github.com/TheRealKerni/QuincyKit/issues/91 without luck.

If I build FOR archiving the debug symbols are included. I ran dwarfdump on the resulting dSYM file and was able to see the symbols for the static libraries implementation files. However when I then attempt to archive the project the symbols are excluded.

Am I missing something? XCode version 4.4.1

like image 244
Trent Ahrens Avatar asked Sep 19 '12 19:09

Trent Ahrens


2 Answers

I m using XCode 5.1.1 and was having the same problem.

The fix was to set "Strip Linked Product" setting under "Deployment" section to "No" for each dependent library project. For more detail, please see my post at

can i debug ios app installed from ipa archive

like image 130
Yevgeniy P Avatar answered Nov 15 '22 06:11

Yevgeniy P


This appears to be fixed in a later version of XCode, currently using 4.6 and the problem went away.

If you are stuck using an older version then do the following: Product > Build For > Archiving Product > Archive Open the built product from derived data, you can do this by right clicking on the Youapp.app file in Products group and selecting show in finder. Ensure you are in the Release-xxx folder. Copy the dSYM file generated there and replace the one produced by the archive process. To find where archived files are go to Organizer, Archives tab, right click on an item and show in finder.

Hope this helps.

like image 40
Trent Ahrens Avatar answered Nov 15 '22 04:11

Trent Ahrens