Hi devs,
I try to use OpenCV SDK for Android v4.5.1 in my java based application at an Android emulator. I have used different approaches which are available -e.g., like this tutorial example. In the end I got every time an error which consumed some time to find a solution or workaround for this:
W/System.err: java.lang.UnsatisfiedLinkError: dlopen failed: library “libc++_shared.so” not found
I checked all steps again, try to do it in another way, but in the end the error still be there. I opened already an issue but I guess maybe you could help me here more fast…
I found the root cause from that error already: The binaries which are located …\sdk\native\libs and copied to src\main}\jniLibs are damaged or something is missing, at least for the x86 build which I am using for my emulator. I don’t know what it is but after replacing the .so files with an older version of openCV .so files, I used v4.1.0 here, everything works fine.
Here are some information about my setup:
Android Studio: 4.1.2, NDK installed
Platform: Android, API 29, in-build Emulator (x86)
Error appears: OpenCV Android SDK > 4.1.0 - e.g., 4.5.1
Dev. Language: Java, loading native c++ libs (*.so)
My question to you is, do anybody also work with java in an Android x86 environment and could tell me what I did wrong? Possibly the binaries are corrupted since 6 releases but I don’t think so… Maybe somebody could tell me how I could fix it by my own so I could use the newest version of openCV?
Greetings