当前位置:网站首页>Solution: direct local.Aar file dependencies are not supported when building an aar
Solution: direct local.Aar file dependencies are not supported when building an aar
2022-07-29 00:07:00 【Sharp surge】
ndroid Studio 4.0+ Version throws the following exception during packaging
Direct local .aar file dependencies are not supported when building an AAR.
The resulting AAR would be broken because the classes and Android resources from any local .aar file dependencies would not be packaged in the resulting AAR.
Previous versions of the Android Gradle Plugin produce broken AARs in this case too (despite not throwing this error).
The following direct local .aar file dependencies of the :XXXXXXXXXX
The solution is as follows :
1. Create a new one module, Major reservations build.gradle file ( Other documents can be deleted )
2. take “The following direct local .aar file dependencies of the :” Post prompted aar Put the file into the new module In the root directory of ,module The directory structure is as follows :

3. modify build.gradle The contents of the document , as follows :
configurations.maybeCreate("default")
artifacts.add("default", file('xxxx.aar'))
// If there are more than one aar, Just need to do it again add
//artifacts.add("default", file('xxxx2.aar'))
//......
//artifacts.add("default", file('xxxxn.aar'))
4. The original aar Of module Go to module The form of depends on new module, The dependency form is compileOnly, as follows :
dependencies {
...
compileOnly project(path: ':newmodule')
...
}
5. Just pack it again
————————————————
Copyright notice : This paper is about CSDN Blogger 「sayhello_class」 The original article of , follow CC 4.0 BY-SA Copyright agreement , For reprint, please attach the original source link and this statement .
Link to the original text :https://blog.csdn.net/sayhello_class/article/details/123047897
边栏推荐
- DevOps在物联网解决方案中的应用
- Centos7 install mysql8
- EN 1873屋面用装配附件.塑料单个屋面灯—CE认证
- 跳表的原理
- Where is the DP interface of desktop computer (what if the host has no DP interface)
- Briefly introduce the working principle and characteristics of block cipher encryption block link mode (cryptography shift cipher encryption and decryption)
- @Transactional 注解使用详解
- EN 1935 building hardware. Single axis hinge - CE certification
- Worthington - chemical properties and related studies of Worthington trypsin
- Leetcode59. 螺旋矩阵 II
猜你喜欢

Uricase - Characteristics of uricase in Worthington pig liver:
![[detailed and super simple] how to use websocket links](/img/bf/5068f84e0d81a8330529cc4d7d5d27.png)
[detailed and super simple] how to use websocket links

Have passed hcip and joined the company of your choice, and share the learning experience and experience of Huawei certification

【C】逆序字符串(俩种递归思路)

Compose 的声明式代码如此简洁?

Leetcode64. 最小路径和

PowerCL 批量创建及管理虚拟交换机

Interpretation of ISO 13400 (doip) standard

研发效能的道法术器

Genomic DNA isolation Worthington ribonuclease A
随机推荐
1-8 props的基础使用
研发效能的道法术器
Classification and determination method of Worthington stemxyme
GhostNets on Heterogeneous Devices via Cheap Operations
curl (7) Failed connect to localhost8080; Connection refused
Word中的\n是什么?:^p
ISO 13400(DoIP)标准解读
多传感器融合定位(三)——惯性技术
laptop外接显示器
2022-07-28:以下go语言代码输出什么?A:AA;B:AB;C:BA;D:BB。 package main import ( “fmt“ ) func
Dual for loop optimization
连接池-归还连接详解(下)
pycharm新建项目
EN 1873 assembly accessories for roofing - plastic single roof lamps - CE certification
Leetcode59. Spiral matrix II
实时数仓:网易严选基于Flink的实时数仓实践
Where is the DP interface of desktop computer (what if the host has no DP interface)
考过HCIP入职心仪公司,分享华为认证学习经历及心得
GhostNets on Heterogeneous Devices via Cheap Operations
Servlet operation principle_ API details_ Advanced path of request response construction (servlet_2)