:app:transformDexArchiveWithExternalLibsDexMergerForDebug'. 问题记载

Error:Execution failed for task ':app:transformDexArchiveWithExternalLibsDexMergerForDebug'.

> java.lang.RuntimeException: com.android.builder.dexing.DexArchiveMergerException: Unable to merge dex

 

 

 该bug 是由于 grade 的依赖包的问题,查看依赖是否重复但是版本不同。

我的问题:

 

compile 'com.google.zxing:core:3.3.0'
implementation files('libs/core-3.1.0.jar')

两个同时依赖的zxing 包,但是版本不同。导致该问题。

也可能出现的问题: 引入的jar包包含此jar包。 eg:

RxTools 包含 zxing jar包

解决: 删除其中认为用不到的jar或者module。

 

你可能感兴趣的:(:app:transformDexArchiveWithExternalLibsDexMergerForDebug'. 问题记载)