When building for the Nexus 9 running Android 7.1.1 our Forms app will crash after relaunching the app 2 ~ 4 times. The logcat says something about issue loading a Unity dependency. I was able to fix this problem by adding the architecture arm64-v8a and linking assembly sdks.
But now that the app is not crashing on launch after reopening there are new issues. We use a midi library called "sonivox" and I have the .so files from this repo:
In the Android project there is a "lib" folder that has several sub-folders which are:
Each subfolder contains "libsonivox.so".
Our app works on the Pixel running 7.1.1 build for armeabi-v7a. But since adding arm64-v8a support for the Nexus 9 running Android 7.1.1, audio playback is broken because there is a disconnect between "libsonivox.so" in the "arm64-v8a" folder getting to the right spot where we can use DllImport to call it's functions.
My debug logs say things like:
[Mono] DllImport error loading library '/system/lib/libsonivox.so': 'dlopen failed: library "/data/app/com.app.smv-1/lib/arm64//system/lib/libsonivox.so" not found'.
Why is it searching "arm64" folders and not "arm64-v8a" folders?
It also has said stuff about un-accessable namespaces.
[linker] library "/system/lib/libsonivox.so" ("/system/lib/libsonivox.so") needed or dlopened by "/data/app/Mono.Android.DebugRuntime-1/lib/arm64/libmonosgen-64bit-2.0.so" is not accessible for the namespace: [name="classloader-namespace", ld_library_paths="", default_library_paths="/data/app/com.app.smv-1/lib/arm64:/system/fake-libs64:/data/app/com.app.smv-1/base.apk!/lib/arm64-v8a", permitted_paths="/data:/mnt/expand:/data/data/com.app.smv"]
Nothing like this happens in armeabi-v7a.
Either we put out a build that does not support Nexus 9 on 7.1.1 or I need to figure out how to get this stupid native library to work for 64 bit since it does not work the same as the armeabi-v7a version.