Search code examples
androidmavenandroid-maven-plugin

Native libraries not being attached to the APK using android-maven-plugin


I am trying to build my Android app using Maven. I am using the android-maven-plugin version 3.0.2 (have tried 3.0.0 too). Everything goes fine but the .so files inside my /libs folder do not get attached. The folder structure is like this:

-android
--src
--assets    
--res
--libs
----armeabi
----armeabi-v7a

I am following the pom.xml as given in one of the native library samples. The APK compiles fine and almost everything runs except the part where I call a native function.

From the samples it doesn't look like anything needs to be done. I have a feeling that only one of the so files is being attached. Has anyone else run into the same problem?


Solution

  • This works for me with the new version of Maven android plugin. Libraries are attached to the APK as expected.