I have an Android app that I have been able to successfully build with Gradle (using Gradle 0.7). Now I want to set up Gradle to build two separate .APKs, one which had only ARM native libraries and the other with only Intel x86 native libraries. I have tried using productFlavors as in the following example:
How to configure NDK with Android Gradle plugin 0.7
However, with productFlavors specified in my Gradle script, the .APKs don't include any libraries at all (the libs dir itself is not in the .APK). Without productFlavors, the libraries are included - although the resulting APK will contain both ARM and x86 libraries.
With Gradle, it seems that our libraries are being placed in the following directories:
build/javaResources/release/lib/armeabi-v7a
build/javaResources/release/lib/x86
build/javaResources/debug/lib/armeabi-v7a
build/javaResources/debug/lib/x86
Without productFlavors in the Gradle script, Gradle seems to know to look in those directories for the libraries. So I'm at a loss as to what's going on. Why would the inclusion of productFlavors prevent Gradle from looking there for the libraries?