I have an android project that uses several libraries:
- play-services for analytics,
- appcompat-v7 for the actionar,
- and others... (for ads, in-app...)
I used to use APKLIB packaging and I was able to generate the APK of my project, but having hundreds of errors in Eclipse. So my intention is to fix this for not having any error at all }:-)
I discovered the AAR format and all this gradle staff, but I'd like to keep using my maven structure as it is.
So I got the AAR package of play_services (thanks to https://github.com/mosabua/maven-android-sdk-deployer) and generated the AAR package of appcompat-v7 and the others libs.
And I almost made this happen, excepting some errors with styles and other missing resources from those libs that are still not found:
Error: No resource found that matches the given name (at 'value' with value '@integer/google_play_services_version').
Error: No resource found that matches the given name (at 'theme' with value '@style/Theme.AppCompat.Light').
This is an example of some of my dependencies:
<dependency>
<groupId>com.google.android.gms</groupId>
<artifactId>play-services</artifactId>
<version>5.0.77</version>
<type>aar</type>
</dependency>
<dependency>
<groupId>com.google.android</groupId>
<artifactId>android</artifactId>
<version>4.1.1.4</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>android.support</groupId>
<artifactId>compatibility-v7-appcompat</artifactId>
<version>20.0.0</version>
<type>jar</type>
</dependency>
<dependency>
<groupId>android.support</groupId>
<artifactId>compatibility-v7-appcompat</artifactId>
<version>20.0.0</version>
<type>aar</type>
</dependency>
<dependency>
<groupId>android.support</groupId>
<artifactId>compatibility-v4</artifactId>
<version>20.0.0</version>
</dependency>
My questions are:
- Does it worth to forget Maven and move to Gradle for using Android apps? (Please say no :)
- Is it not possible to get the dependencies resources using AAR packaging? I don't want to import all my projects in Eclipse for having access to their resources.