New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
iOS Crash on App Start with this error: symbol '_$s10Foundation10CocoaErrorV4CodeVAA01_cD8ProtocolAAMc' not found, expected in '/System/Library/Frameworks/Foundation.framework/Foundation' #2768
Comments
Yes, according to the latest iPhoneOS SDK, that symbol is found in the Foundation framework, but it seems on older phones this isn't the case and the app should instead pick it up from the Swift library. Potentially we can change the linker order to try to get this working, but we may need to check how it handles it when you use Xcode for this directly. I assume you have an ANE involved here? See also #2685 |
Hi @ajwfrost , Is there a solution for this problem? What is the miminum iOS version for app not to have this crash? We currently cannot issue new iOS builds because of this issue, This is project.apm (note not using Iron source nor using any iron source mediations) Thanks |
Hi Can you please try re-packaging using the ADT version from the attached (this can be copied over the latest AIR SDK, in the "lib" folder, once it's unzipped..) I am hoping that the re-ordering of the linker commands will mean that the symbols are picked up from the Swift foundation library now, rather than the framework... It would be good if you're also able to have logging enabled when building, either via an adt.log file or via the AIR SDK Manager "troubleshooting" tab, so that we can see the updated ld64 command line...? thanks Andrew |
Hi The linking line has thanks |
Hi |
@shaymolho Are you using our ANEs? Let me know which ones and I'll add this flag into it for you. |
I would assume both libraries are needed here. Is the swift code (that's in these ANEs) part of some third party components? If not, do we know whether there's usage of something like the I'm wondering whether this is behind that missing symbol... (hoping we could perhaps set up a reproduction of this scenario here!) thanks |
@marchbold yes, u can see the app descriptor in a few comments above |
the ANE that adds the lSwiftCompat is |
Yep, I'll get a test version of it built this morning. |
This build has the flag: com.google.firebase.core.ane.zip |
did u change anything else or just added the flag to platform,xml? because i built with manually adding this flag (adt.log attached) and still crashes: |
I just added the additional flag. I don't see it in your log though are you certain you updated? Make sure you clear all caches etc if using an IDE. |
i see it in the log: |
Ah there are two builds in the log, I only looked at the first one which doesn't have it. |
i"m trying with your ANE now, will update soon |
device-log.txt |
crash-log.zip |
Hmm.. so despite that, it's still got the missing symbol:
Will need to check a bit further - we can just exclude it from the Foundation stub, but we'd likely have a number of symbols that need to change here.. thanks |
ok, thanks |
Trying to help, I did a build the 50.2.3 SDK and with the adt.jar posted here. In both cases, when running the application on 15.7.8 I got the following error: dyld[1163]: Symbol not found: (_$s10Foundation4DataV15withUnsafeBytesyxxSWKXEKlF) I will have to investigate how to generate a log file out of adt as my commands are wrapped up in build scripts that I'll have to poke around in. |
I added
|
(iOS 12-15 seems to be working with this one so same result there). |
Okay thanks - we'd better address that simulator swift linking issue..
Just to check, does this mean the crash-on-startup reported under https://github.com/distriqt/ANE-Firebase/issues/462 looks like it's fixed with this update to ADT in conjunction with your latest ANE update? thanks |
Yep, that one should be resolved with this update. Just the simulator issue now |
So currently there's the "libSwiftCompat.a" archive in the SDK 'lib' folder, and I'm assuming your ANE will be including the Below is a zip that contains an updated version of libSwiftCompat.a which is a fat/universal file with arm64 and x86_64 versions, if you unzip this into the SDK lib/aot/lib folder, and try again, I would hope this time it works..! thanks |
Bingo! Looks good with that addition :) (Yep our ANEs that rely on this have the |
Hey @ajwfrost, Maybe it's a different issue i don't understand , (By The way, where can i find the adt.log file? can't find it in the user home dir) Thanks |
Curious one .. the adt.log file should be under /Users/username/adt.log but only if you've configured this to appear, by adding a line "DebugOut=true" to a file /Users/username/.airsdk/adt.cfg. thanks |
@marchbold Our issue on #2860 is the same as @takazawa-gg described! (Can't run on ios < 16) |
Hi @ajwfrost, Waiting for your response. Thanks |
Hi @shaymolho - we're not able to reproduce that here and the log file doesn't really suggest much happening on the code-signing front! A couple of options perhaps:
thanks |
HI @ajwfrost , I did both things and it didn't work. We need this app in simulator mode, What can i do now? |
@ajwfrost maybe u can add more logging to pinpoint the codesign issue? |
@ajwfrost reminder |
Hi - thanks for the reminder, we can put together an ADT version with some additional logging per your suggestion; to start with though are you able to enable debugging and confirm what it says in terms of the command-line for the code signing? The simplest way to do this is to have the AIR SDK Manager installed, and open this to the "Troubleshooting" page? thanks |
Just found this thread. Users of our live app are reporting crashes when on older iOS versions. We don't have an older iOS device here to test with, but so I understand, do we need to do the following?
Then we're golden? Separately, @marchbold I see you linked a test version of Firebase up there. Could this also solve the issues I've had (and reported elsewhere) building the app for iOS with Firebase included? Thanks guys |
Hi @mrfrasier - the changes from above for ADT and libSwiftCompat.a should be in 50.2.3.6 already, so in terms of the crash on older iOS versions, that should have been fixed by that (iirc, a re-ordering of the libraries/frameworks that we link against..) thanks |
Thanks for the reply. My app is actually built with 2.3.6 with the updated overlay files as that solved another issue I was having, but my users still report that the app crashes right back out on iOS versions under 16. I did manage to get my hands on a device and witnessed the same behavior sadly. What data can I provide to help track down the issue? |
If you're able to get the crash report it would be handy .. Settings -> Privacy & Security -> Analytics & Improvements -> Analytics Data, then you'll see a long list of crash reports, if you find yours by process name (filename from the app descriptor file) there's a "send to" option at the top right of the screen. thanks |
Hi Andrew, please see attached |
Thanks .. that does look similar to the issue we were getting with the out-of-order linking, although not a symbol/library that I recognise:
But again with "Foundation" which is the issue we had earlier, where symbols were expected to be in Foundation but weren't. This may be the other way round..! Did you build this on Windows, or macOS? And are you able to provide the ld64 command line (if you use the SDK Manager Troubleshooting tab, when packaging the IPA file it should display this line..)? |
Yup, on Windows here. here is the ld64 command (this build fails because I'm simultaneously trying to figure out a Firebase issue with Michael and that problematic ANE is present, but figured you just needed to see the general command) This is on 50.2.3.7
|
I have similar feedbacks from users (IOS < 16) Windows P.S. I check the same version of ld64 is within AIR50.2.3.7 now |
Hi So that missing symbol appears a few times online, seems to have caused a number of issues.. but to try to work out where it would come from: we have it in three places in the latest iPhone SDK:
In the binary above, it seems to be looking for it in the dyld cache.. This may be something related to how we're handling these TBD files and turning them into libraries, potentially we're seeing them coming from the wrong place. You're both using Windows to compile this, do you have any access to a mac to try that? I would be interested in the results both with and without the In terms of reproducing this: do you know if it's 100% reproducible, with the binaries you've built on Windows, when using the older (iOS 15 and earlier) versions? Also, I don't think we've ever got a reproduction scenario so is there any chance we could get a set of files (XML/SWF/ANEs) so that we can package it and test it here to reproduce the problem? We have a potential workaround, although a lot of that may depend on whether it also fails if you built it on a macOS machine using the If you can help with a reproduction - either by sending us your app files, or by trying something out for us if you're able to reproduce things there - then please email me, andrew dot frost at harman dot com.. thanks |
Can production version of app help you? You will see crashes on old IOS versions. |
As long as it's in a form that we can package up an IPA from it .. but just getting an IPA is probably of limited value as we'd not be able to do much to tweak the settings and try to reproduce and then fix it.. |
@Mintonist Please do not distribute our ANEs on public forums. |
@marchbold please excuse me! my mistake... |
This crash occurs on iPhone SE 2016 with IOS 13.4.1
Using lastest air sdk 50.2.3.3 and latest x code 14.3.1
crash log is here
crash-2023-08-16-093209.ips.zip
on another iOS the app works fine
device logs here
log2.txt
ipa is here
https://easyupload.io/4hzsvc
any idea?
The text was updated successfully, but these errors were encountered: