ScottyB
ScottyB

Reputation: 2497

Strange errors when attempting to Symbolicate iOS crash report

I received a crash report from Apple, and followed these instructions to symbolicate it: How to symbolicate crash report from Apple received in .txt format not .crash format

Unfortunately, I see errors when I execute step 7 ("./symbolicatecrash ..."), and don't find an SO question that addresses them:

xcodebuild: error: SDK "xxxos" cannot be located.
xcrun: error: unable to find utility "otool", not a developer tool or in PATH
## Warning: can't find tool named 'otool' in the xxxos SDK, falling back to searching the iOS SDK
xcodebuild: error: SDK "xxxos" cannot be located.
xcrun: error: unable to find utility "atos", not a developer tool or in PATH
## Warning: can't find tool named 'atos' in the xxxos SDK, falling back to searching the iOS SDK
xcodebuild: error: SDK "xxxos" cannot be located.
xcrun: error: unable to find utility "symbols", not a developer tool or in PATH
## Warning: can't find tool named 'symbols' in the xxxos SDK, falling back to searching the iOS SDK
xcodebuild: error: SDK "xxxos" cannot be located.
xcrun: error: unable to find utility "size", not a developer tool or in PATH
## Warning: can't find tool named 'size' in the xxxos SDK, falling back to searching the iOS SDK
No symbolic information found

Notes:

Any idea what's going on and how to fix it? Thanks!

Added the parse_SDKGuess function in the symbolicatecrash script for reference:

sub parse_SDKGuess {
    my ($log_ref) = @_;

    # It turns out that most SDKs are named "lowercased(HardwareModelWithoutNumbers) + os",
    # so attempt to form a valid SDK name from that. Any code that uses this must NOT rely
    # on this guess being accurate and should fallback to whatever logic makes sense for the situation
    my $model = parse_HardwareModel($log_ref);
    $model or return undef;

    $model =~ /(\D+)\d/;
    $1 or return undef;

    my $sdk = lc($1) . "os";
    if($sdk eq "ipodos" || $sdk eq "ipados") {
        $sdk = "iphoneos";
    }
    if ( $sdk =~ /mac/) {
        $sdk = "macosx";
    }

    return $sdk;
}

It seems that "lc($1)" evaluates to "xxx"...

Upvotes: 2

Views: 4609

Answers (1)

Marián Černý
Marián Černý

Reputation: 15778

SDK "xxxos" cannot be located

You can probably ignore those errors. The reason of those errors is that the crash report from Apple contains the following in the crash report:

Hardware Model:      xxx1

(instead of for example iPhone10,5). Apple probably masks the hardware model. They might be using a special hardware for testing.

As the warnings show xxxos SDK is not found and it falls back to iOS.

No symbolic information found

I guess this is an unrelated issue to the xxxos errors.

What worked for me was downloading dSYMs from Apple. Go to Xcode > Organizer, in the Archives tab (the default) select your App and the version that corresponds to your crash report and click on the "Download dSYMs..." button.

After the dSYMs are downloaded, re-run the symbolicatecrash command:

./symbolicatecrash mycrash.crash > symbolicated.crash

I guess the problem is that when you enable bitcode, Apple is rebuilding the application and then the generated dSYMs in xcarchive do not match the crash report.

And even then all calls from my code were symbolicated properly, but calls in system frameworks (e.g. UIKit) were not symbolicated.

Upvotes: 5

Related Questions