1 | initial version |
This might help.
2 | No.2 Revision |
This might help.
Let me quote from the answer.
The error appears when you are trying to add a dependency which is an APK using:
apply plugin: 'com.android.application'
tells Gradle to build it as an application, generating an APK using:
apply plugin: 'com.android.library'
it will build as a library, generating an AAR.
Check the link for more detail