且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

外部的Andr​​oid库项目摇篮

更新时间:2023-01-04 11:32:21

虽然可以通过一个Maven或常春藤库中获得的依赖性,这些都不是封装在一个标准的JAR归档。有专门为此构建系统设计了一种新的格式。该类型是AAR

While it is possible to get dependencies through a Maven or Ivy repository, those are not packaged in a standard Jar archive. There is a new format designed specifically for this build system. The type is 'aar'

适用于Maven的中间当前的Andr​​oid库,以便它们是不兼容的。

Current Android Libraries available on Maven Central were created using the Maven plugin which use a different archive format ('apklib') so they are not compatible.

如果你看一下com.actionbarsherlock:actionbacksherlock(这是该库的新位置),你会看到它的格式是apklib。 http://search.maven.org/#artifactdetails%7Ccom.actionbarsherlock%7Cactionbarsherlock%7C4.2.0%7Capklib

If you look at com.actionbarsherlock:actionbacksherlock (which is the new location of that library), you'll see its format is apklib. http://search.maven.org/#artifactdetails%7Ccom.actionbarsherlock%7Cactionbarsherlock%7C4.2.0%7Capklib

查看源$ C ​​$ C,我们检查'AAR'包装和恢复处理所有其他的罐子,这显然是一个问题就在这里。我们应该检测apklib并提供更好的错误消息。

Looking at the source code, we check for 'aar' packaging and revert to processing all others as 'jar' which is obviously a problem here. We should detect apklib and provide a better error message.