Android dependencies : apklib vs aar files
aar differ from apklib in one major way : classes are compiled and included in a classes.jar in the root of the aar. Whereas
apklib cannot contain compiled class files or jars.
1 Can somebody explain the main differences between
aar files ?
aar ? Can
3 Which format is “better” ?
One Solution collect form web for “Android dependencies : apklib vs aar files”
1 Can somebody explain the main differences between apklib vs aar
Couple differences that comes to my mind, in addition to the one you said:
aarcan contain no source code and a java jar inside the
libsfolder in case you don’t want to provide the source code (like Google Play Services does);
aarcan contain custom proguard file and custom lint rules, although I’m not sure they are take into account at the moment.
2 Can Maven use aar ? Can Gradle use apklib ?
The Android Maven Plugin supports
aar since version 3.7.0.
Gradle doesn’t support using
apklib dependencies but you could export your
apklib (see this post).