Can't find libandroid.so
Description
Caused by: com.getkeepsafe.relinker.MissingLibraryException: Could not find 'libandroid.so'. Looked for: [armeabi-v7a, armeabi], but only found: []. at com.getkeepsafe.relinker.ApkLibraryInstaller.installLibrary(ApkLibraryInstaller.java:175) at com.getkeepsafe.relinker.ReLinkerInstance.loadLibraryInternal(ReLinkerInstance.java:180) at com.getkeepsafe.relinker.ReLinkerInstance.loadLibrary(ReLinkerInstance.java:136) at com.getkeepsafe.relinker.ReLinkerInstance.loadLibrary(ReLinkerInstance.java:92) at com.getkeepsafe.relinker.ReLinkerInstance.loadLibraryInternal(ReLinkerInstance.java:197) at com.getkeepsafe.relinker.ReLinkerInstance.loadLibrary(ReLinkerInstance.java:136) at com.getkeepsafe.relinker.ReLinkerInstance.loadLibrary(ReLinkerInstance.java:92) at app.rive.runtime.kotlin.core.Rive.init(Rive.kt:57) at app.rive.runtime.kotlin.core.Rive.init$default(Rive.kt:46)
Versions, Device, and Other Information
- Rive Android Runtime Version: 11.1.1
- Rive API:
- Device:
- App Minimum SDK Level: 24
- App Target SDK Level: 35
- App NDK Level:
- Frequency:
- Other Rive runtimes affected:
- Dependencies with native libraries:
Reproduction Steps
Source .riv/.rev File
Expected Behavior
Screenshots
Additional context
Same with simulator.
Process: com.ravenfeld.maps, PID: 7151
java.lang.RuntimeException: Unable to get provider androidx.startup.InitializationProvider: f6.c: com.getkeepsafe.relinker.MissingLibraryException: Could not find 'libandroid.so'. Looked for: [x86], but only found: [].
at android.app.ActivityThread.installProvider(ActivityThread.java:6288)
at android.app.ActivityThread.installContentProviders(ActivityThread.java:5851)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5772)
at android.app.ActivityThread.-wrap1(Unknown Source)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1661)
at android.os.Handler.dispatchMessage(Handler.java:105)
at android.os.Looper.loop(Looper.java:164)
at android.app.ActivityThread.main(ActivityThread.java:6541)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.Zygote$MethodAndArgsCaller.run(Zygote.java:240)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:767)
Caused by: f6.c: com.getkeepsafe.relinker.MissingLibraryException: Could not find 'libandroid.so'. Looked for: [x86], but only found: [].
I did see that for user on Chromebook 11 Model 3180 Android 9
Hey, thank you for the report. We're aware of this and it's currently a top priority. Thank you for your patience while be debug this.
If you need more statistics on devices on which this is occurring:
I am experiencing the same issue as well. I am currently using the latest version (11.1.1).
Is this fixed in the release 11.1.2?
@eabdelmoaty This issue is not yet resolved, unfortunately. I'll be sure to write a note here when it's fixed.
@tylernij, Please update. Is there a fix for this crash on SDK V 11.2.0?
Is there a working version to roll back to?
Is there a working version to roll back to?
10.3.3
@tylernij, Please update. Is there a fix for this crash on SDK V 11.2.0?
We do not yet have a fix, but progress is being made. I'll be sure to update as soon as I have new information 👍
Is there a working version to roll back to?
10.3.3
Based on my understanding, you may be able to get all the way to version 11.0.0 without being impacted by this, but I've not personally tried it, we definitely don't experience it on 10.5.3, which is the last version before 11.0.0
Is there a working version to roll back to?
10.3.3
Based on my understanding, you may be able to get all the way to version
11.0.0without being impacted by this, but I've not personally tried it, we definitely don't experience it on10.5.3, which is the last version before11.0.0
According to our data, 10.5.3 also causes the crash. With that said, we did go a full version with 10.5.3 without being impacted by this so I am confused. Put another way:
- We updated to
10.5.3in version 1. No crashes in version 1 were observed. - Version 2 released without updates to Rive. Crashes were observed.
Is there a working version to roll back to?
10.3.3
Based on my understanding, you may be able to get all the way to version
11.0.0without being impacted by this, but I've not personally tried it, we definitely don't experience it on10.5.3, which is the last version before11.0.0According to our data,
10.5.3also causes the crash. With that said, we did go a full version with10.5.3without being impacted by this so I am confused. Put another way:
- We updated to
10.5.3in version 1. No crashes in version 1 were observed.- Version 2 released without updates to Rive. Crashes were observed.
Are you sure the crashes you saw were specifically regarding failing to load libandroid.so and not a different .so file? We have had many releases on 10.5.3 and not seen libandroid.so relinker crashes. I actually did go back through our crashes and saw some on 10.5.1 but also not anywhere at the scale we saw with 11.1.0
Is there a working version to roll back to?
10.3.3
Based on my understanding, you may be able to get all the way to version
11.0.0without being impacted by this, but I've not personally tried it, we definitely don't experience it on10.5.3, which is the last version before11.0.0According to our data,
10.5.3also causes the crash. With that said, we did go a full version with10.5.3without being impacted by this so I am confused. Put another way:
- We updated to
10.5.3in version 1. No crashes in version 1 were observed.- Version 2 released without updates to Rive. Crashes were observed.
Are you sure the crashes you saw were specifically regarding failing to load
libandroid.soand not a different.sofile? We have had many releases on10.5.3and not seenlibandroid.sorelinker crashes. I actually did go back through our crashes and saw some on10.5.1but also not anywhere at the scale we saw with11.1.0
Sure, I'll look this again and see.
Has any progress been made on this, and a rough time to when this might be included in prod?
STILL NO PROGRESS? RIVE TEAM SUCKS.....
We don't have any solid leads on this as we haven't been able to reproduce locally. libandroid.so missing could be a red herring, since it's quite unlikely that the library itself is missing - it should be provided by the OS.
For those affected, there is one possibility that I'd like to see if it may be a shared root cause. Do your apps use "Play Feature Delivery" or "on demand feature delivery"? This would cause the APK to be split. If that's the case, it may be that librive-android.so which has libandroid.so as a dependency is loaded first triggering the above error, which would be re-interpreted not as "not found" but rather "not yet loaded". See this article in the docs.
For all those affected, if you could check if this is the case for your app, we can then look at solutions. It may be that you need to load the native Rive library yourself using e.g. SplitInstallHelper.loadLibrary.
I've got a fix in progress that may advance the issue on this. The theory is that ReLinker's recursive linking attempts, in a failure mode, would attempt to resolve libandroid.so from the APK's lib folder, which will always fail. This failure would obscure the original failure to load librive_android.so which we want to surface. Once the patch is in, we should stop seeing this error but it may surface the true error, which we will need to fix separately. That is of course assuming the theory is correct!
does 11.6.0 fix it?? Rive init cause many anr during application on create。。。。