kggoh kggoh - 26 days ago 9
Android Question

building an aar module

First time i build an aar module. I am able to convert my app into an aar module. And i create another new app, and add this aar file into the project. However, I encountered this error.

Error:(9) No resource identifier found for attribute 'civ_border_color' in package 'com.example.com'


I have searched for the answer, and recommendation like
replacing
xmlns:app="http://schemas.android.com/apk/res-auto"
with
xmlns:app="http://schemas.android.com/apk/lib-auto" or
xmlns:app="http://schemas.android.com/apk/com.example.com"

I have tried. And i notice the files that have error, are auto generate files, i am not suppose to change them. Is there any steps that i have missed out creating the aar file. BTW, the compilation of the aar file is successful. Any useful information that i missed out , please do point out. Not vote down. Coz i really have no idea what I have missed out. Thanks.

Answer Source

Did you add

repositories {
  flatDir {
     dirs 'libs'
  }
}

in your project's build.gradle?

Did you add

compile(name: 'xxx', ext: 'aar')。

in your module's build.gradle?