13

This is a very weird problem. I think I must be doing something wrong, but I don't know what it is. I've been using symbolicatecrash for several years with no problems. The issue I'm seeing is that symbolicatecrash is not showing symbols for the system libraries, but it IS showing symbols for my application. I've tried everything I can think of to resolve this with no luck.

Note that I'm getting the same results on three different machines, 2 Lion, 1 Snow Leopard.

Example command line: /Developer/Platforms/iPhoneOS.platform/Developer/Library/PrivateFrameworks/DTDeviceKit.framework/Versions/A/Resources/symbolicatecrash /Users/mike/Downloads/mycrash-iPad.crash

Note also that I get the same results when I drag the file into the logs section of the XCode 4.2 logs organizer window and wait for XCode to symbolicate the file.

Here's an example of a crash in my code with the partially symbolicated symbols:

Last Exception Backtrace:
0   CoreFoundation                  0x33dae8bf 0x33cf5000 + 759999
1   libobjc.A.dylib                 0x354ca1e5 0x354c1000 + 37349
2   CoreFoundation                  0x33dae7b9 0x33cf5000 + 759737
3   CoreFoundation                  0x33dae7db 0x33cf5000 + 759771
4   CoreFoundation                  0x33d1b6bb 0x33cf5000 + 157371
5   myZenfolio                      0x001a551d -[GtDataSourceManager setDataSource:forKey:] (GtDataSource.m:59)
6   myZenfolio                      0x0004c793 -[ZfUserAccountViewController doUpdateDataSourceManager:] (ZfUserAccountViewController.m:202)
7   myZenfolio                      0x0022f853 -[GtEditObjectViewController tableViewWillReloadData:] (GtEditObjectViewController.m:803)
8   CoreFoundation                  0x33d0d22b 0x33cf5000 + 98859
9   myZenfolio                      0x002557b9 -[GtTableView reloadData] (GtTableView.m:48)
10  myZenfolio                      0x0004c36d -[ZfUserAccountViewController _updateFromCache] (ZfUserAccountViewController.m:160)
11  CoreFoundation                  0x33d0d22b 0x33cf5000 + 98859
12  Foundation                      0x3187c757 0x317d8000 + 673623
13  CoreFoundation                  0x33d82b03 0x33cf5000 + 580355
14  CoreFoundation                  0x33d822cf 0x33cf5000 + 578255
15  CoreFoundation                  0x33d81075 0x33cf5000 + 573557
16  CoreFoundation                  0x33d044dd 0x33cf5000 + 62685
17  CoreFoundation                  0x33d043a5 0x33cf5000 + 62373
18  GraphicsServices                0x35944fcd 0x35941000 + 16333
19  UIKit                           0x34e49743 0x34e18000 + 202563
20  myZenfolio                      0x00004017 main (main.m:15)
21  myZenfolio                      0x00003fd0 start + 40

I've run the symbolicate crash command with -v and it's finding the app.dSym files okay, it just doesn't seem to be finding the library symfiles which seems to be the opposite problem most people are having. Facepalm.

For example, here's the output from a -v run for the CoreFoundation lib:

............fetching symbol file for CoreFoundation--[undef] 
Searching [/Developer/Platforms/iPhoneOS.platform/DeviceSupport/5.0 (9A334)/Symbols/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation /Developer/Platforms/iPhoneOS.platform/DeviceSupport/Latest/Symbols/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation]...--[/Developer/Platforms/iPhoneOS.platform/DeviceSupport/5.0 (9A334)/Symbols/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation] Running xcrun -sdk iphoneos lipo -info '/Developer/Platforms/iPhoneOS.platform/DeviceSupport/5.0 (9A334)/Symbols/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation'
Running xcrun -sdk iphoneos otool -arch armv7 -l '/Developer/Platforms/iPhoneOS.platform/DeviceSupport/5.0 (9A334)/Symbols/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation'
Given UUID de9eefc6109735369cfd8f3de9895da0 for '/Developer/Platforms/iPhoneOS.platform/DeviceSupport/5.0 (9A334)/Symbols/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation' is really UUID a2dbc131fdc0364e822339ca2926b6e8
-- NO MATCH
--[/Developer/Platforms/iPhoneOS.platform/DeviceSupport/Latest/Symbols/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation] Running xcrun -sdk iphoneos lipo -info '/Developer/Platforms/iPhoneOS.platform/DeviceSupport/Latest/Symbols/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation'
Running xcrun -sdk iphoneos otool -arch armv7 -l '/Developer/Platforms/iPhoneOS.platform/DeviceSupport/Latest/Symbols/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation'
Given UUID de9eefc6109735369cfd8f3de9895da0 for '/Developer/Platforms/iPhoneOS.platform/DeviceSupport/Latest/Symbols/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation' is really UUID a2dbc131fdc0364e822339ca2926b6e8
-- NO MATCH
Searching in Spotlight for dsym with UUID of de9eefc6109735369cfd8f3de9895da0
Running mdfind "com_apple_xcode_dsym_uuids == DE9EEFC6-1097-3536-9CFD-8F3DE9895DA0"
@dsym_paths = (  )
@exec_names = (  )
Did not find executable for dsym
## Warning: Can't find any unstripped binary that matches version of /System/Library/Frameworks/CoreFoundation.framework/CoreFoundation

I really am at a loss to figure out what to try next.

Does anyone have any ideas? I'm fresh out. Your help will be much appreciated!

thanks, Mike

More info, now I'm getting an error in the symbolicatecrash output.

/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/size: for architecture armv7 object: /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/System/Library/Frameworks/Foundation.framework/Foundation truncated or malformed object (dataoff field of LC_FUNCTION_STARTS command 22 extends past the end of the file)
Error in symbol file for /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/System/Library/Frameworks/Foundation.framework/Foundation
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/size: for architecture armv7 object: /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/System/Library/PrivateFrameworks/GraphicsServices.framework/GraphicsServices truncated or malformed object (dataoff field of LC_FUNCTION_STARTS command 17 extends past the end of the file)
Error in symbol file for /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/System/Library/PrivateFrameworks/GraphicsServices.framework/GraphicsServices
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/size: for architecture armv7 object: /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/System/Library/Frameworks/UIKit.framework/UIKit truncated or malformed object (dataoff field of LC_FUNCTION_STARTS command 41 extends past the end of the file)
Error in symbol file for /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/System/Library/Frameworks/UIKit.framework/UIKit
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/size: for architecture armv7 object: /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/System/Library/PrivateFrameworks/WebCore.framework/WebCore truncated or malformed object (dataoff field of LC_FUNCTION_STARTS command 28 extends past the end of the file)
Error in symbol file for /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/System/Library/PrivateFrameworks/WebCore.framework/WebCore
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/size: for architecture armv7 object: /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/usr/lib/libobjc.A.dylib truncated or malformed object (dataoff field of LC_FUNCTION_STARTS command 12 extends past the end of the file)
Error in symbol file for /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/usr/lib/libobjc.A.dylib
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/size: for architecture armv7 object: /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/usr/lib/system/libdispatch.dylib truncated or malformed object (dataoff field of LC_FUNCTION_STARTS command 11 extends past the end of the file)
Error in symbol file for /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/usr/lib/system/libdispatch.dylib
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/size: for architecture armv7 object: /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/usr/lib/system/libsystem_c.dylib truncated or malformed object (dataoff field of LC_FUNCTION_STARTS command 11 extends past the end of the file)
Error in symbol file for /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/usr/lib/system/libsystem_c.dylib
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/size: for architecture armv7 object: /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation truncated or malformed object (dataoff field of LC_FUNCTION_STARTS command 15 extends past the end of the file)
Error in symbol file for /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/size: for architecture armv7 object: /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/usr/lib/system/libsystem_kernel.dylib truncated or malformed object (dataoff field of LC_FUNCTION_STARTS command 10 extends past the end of the file)
Error in symbol file for /Users/mike/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/usr/lib/system/libsystem_kernel.dylib
Mike Fullerton
  • 191
  • 2
  • 10

2 Answers2

13

The following solved the problem for me:

  • Delete the folder ~/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)
  • Reattach your iOS device and it will automatically import the correct symbols.

After that the crash reports could be symbolicated correctly. (to re-symbolicate a crash report, open the Organizer, click on 'Reveal in Finder' and delete the symbolicated version)

ARsteve
  • 436
  • 2
  • 4
  • What version of Xcode are you using? I reimported the symbol files from both an iPad 1 and an iPhone 4 and got the same result both times. This is with Xcode 4.2, the last supported version on Snow Leopard. – arlomedia Dec 10 '11 at 01:06
  • 4
    This worked. I deleted the symbols from the Mac and then attached a different 5.0.1 device and then it worked properly. If I try again with fresh symbols with my iPhone 4s it doesn't work properly, with the symbols from an iPad, it works. Must be corrupted on the phone somehow. Thanks – Mike Fullerton Dec 18 '11 at 00:00
  • I'm Using XCode Version 4.2.1 Build 4D502 on Lion. – ARsteve Dec 21 '11 at 13:25
  • I just wanted to add this worked for me but, as @MikeFullerton said above, it only worked when I imported symbols from my iPad. When I previously tried with my iPhone 4S it still wouldn't symbolicate. – Daniel Wood Dec 23 '11 at 16:48
  • Okay, this worked for me after I upgraded to Lion and installed Xcode 4.2.1. – arlomedia Jan 27 '12 at 01:43
  • 1
    Can you do this without owning a device running the given iOS version? e.g. symbolication of a crash report from the field of a device you don't own? – jpap Jun 25 '13 at 10:25
2

It looks like this is an acknowledged bug with Xcode 4.2 and iOS 5:

https://devforums.apple.com/message/578722

A new Xcode beta was released for Lion yesterday, does that work for you? I can't try it myself because it's not available for Snow Leopard yet.

arlomedia
  • 8,534
  • 5
  • 60
  • 108
  • I haven't tried it yet. Though the release notes do say that the new preview release of XCode breaks symbolicatecrash reporting and that to symbolicate crashes, we need to delete the preview release. I'll probably wait a bit until they fix this to install the preview release. – Mike Fullerton Dec 18 '11 at 00:02
  • Were you able to find a workaround for this? I'm using XCode 4.3.2 and seeing this on simulator as well (5.1) – ilker Acar Aug 06 '12 at 09:44
  • Since posting that answer, I upgraded to Lion and then Mountain Lion and am now running Xcode 4.4. I can't remember for sure, but I think moving to Lion and Xcode 4.3 fixed that particular problem, so you must be seeing a different problem. If you have access to the developer forums, you can review some of the troubleshooting resources that have helped me: https://devforums.apple.com/message/636623#636623 – arlomedia Aug 07 '12 at 00:34