版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/kongbaidepao/article/details/86479132
1.添加本项目libs中的 aar
build.gradle
-------------------------
android{
}
//添加
repositories{
flatDir{
dirs 'libs'
}
}
dependencies{
compile fileTree(dir:'libs', include: ['*.jar'])
//添加依赖aar
compile (name: 'abc', ext:'aar')
}
2. 添加公共引用的 aar
build.gradle
-------------------------------------
dependencies{
compile fileTree(dir:'libs', include: ['*.jar'])
//添加公共 aar,
implementation fileTree (include:['*.aar'], dir:'../../../../commonAAR')
}
编译引用出来的路径: app/build/intermediates/exploded-aar/