如何包括库的本地依赖性AAR
我正在构建一个取决于其他模块的模块。到目前为止,所有模块都已在同一项目中使用,但是现在我需要将其中一个模块作为独立运输。例如,我有模块core
,util
,功能
和app
。到目前为止,功能
正在使用core
和util
with 实现项目(':core')
and code>和实施项目(':util')
。 应用程序
也是如此。现在,当我为功能
构建aar
时,我注意到从aar
中不存在其他模块的代码。如果我尝试发布它,则maven-publish
尝试使用本地依赖关系生成pom
。我可以为功能
生成aar
,其中包括core> core
和util
在其二进制中,而不必必须首先发布其他模块并将它们添加到pom
中?
更新:看来我尝试实现的目标不是直接的,显然有一个问题为此,Google正在“积极地工作”。同时,我必须找到解决方法。
I'm building a module which depends on other modules. So far all modules have been used within the same project, but now I need to ship one of the modules as a standalone. For example I have modules Core
, Util
, Feature
and App
. Until now, Feature
was using Core
and Util
with implementation project(':core')
and implementation project(':util')
. Same goes for App
. Now when I built the aar
for Feature
, I noticed that other modules' code is absent from the aar
. If I try to publish it, maven-publish
tries to generate a pom
with the local dependencies. Can I generate an aar
for Feature
, that includes both Core
and Util
in its binary, instead of having to publish the other modules first and adding them to the pom
?
Update: it seems that what I try to achieve is not straight-forward possible and apparently there is an issue on google tracker for this and Google is "actively working" on it. In the meantime I have to find a workaround.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论