1

I used a physical machine to develop and try to load the .so file. I put all .so file under the "app/libs" folder and add the code at build.gradle

sourceSets {
        main {
            jniLibs.srcDirs = ['libs']
        }

    }

The application performed good. But when I used virtual device to develop instead, it can not load the .so file. Android Studio print the error :

No implementation found for void jsqlite.Database.internal_init()

at the code new jsqlite.Database(); It is a method of spatialite.

I try to create a new folder "src/main/jniLibs" and put the .so file in it, but it doesn't work. How to solve the problem? And I also notice that the virtual devices has a inner file: "/data/data/xxxxx/lib", it has any effect?

Aniruddh Parihar
  • 3,072
  • 3
  • 21
  • 39
leomessi
  • 69
  • 6
  • With ABI does the virtual device use? Have you built all your native libraries for that ABI? – Michael Sep 10 '21 at 10:15
  • the virtual device is Nexus 10 API 30 , the CPU/ABI is x86, I had built the arm64-v8a, armeabi-v7a , x86_64 – leomessi Sep 10 '21 at 10:26
  • 1
    Well, then you'll eiher have to build for x86 as well, or modify your AVD to use one of those other 3 ABIs instead. – Michael Sep 10 '21 at 10:28

0 Answers0