adwiv / android-fat-aar

Gradle script that allows you to merge and embed dependencies in generted aar file
The Unlicense
1.46k stars 435 forks source link

Can I embed local .aar libraries? #8

Closed fgsantoyo closed 8 years ago

fgsantoyo commented 8 years ago

Hi Adwiv,

I have custom libraries packaged as aar that I'd like to include in my fat aar. Is this supported by this script?

Thanks,

Fernando

adwiv commented 8 years ago

Are they in the local filesystem? Where are they placed? How do you include these aar files as dependencies?

fgsantoyo commented 8 years ago

Right now they are in my libs folder and included like the following.

repositories { //This allows third party (aar) libraries included in the "libs" folder to be picked up by the compiler flatDir { dirs 'libs' } }

dependencies { compile fileTree(dir: 'libs', include: ['*.jar']) //... other dependencies compile 'com.enterprise.android.common:common@aar' }

adwiv commented 8 years ago

If it is included like this, it should probably work. I haven't tried myself this way although. Do you get any issues?

adwiv commented 8 years ago

The correct way to embed local aar files is to import them as a separate module in the project. File -> New Module -> Import Jar/AAR file Closing the issue.