我更新了所有内置工具、支持库和 google Play 服务。 但我仍然收到以下错误:
Error:Execution failed for task ':app:shrinkReleaseMultiDexComponents'
java.io.IOException: The output jar [app\build\intermediates\multi-dex\release\componentClasses.jar] must be specified after an input jar, or it will be empty.
我可以通过将 minifyEnabled
设置为 false
来解决这个问题,但这不是我想要的。有谁知道如何修复它?
最佳答案
我终于可以生成 APK 了
minifyEnabled to true
实际上问题是一些重复的类给出了一些我没有注意到的警告。
对我来说,我添加了
-dontwarn com.aphidmobile.**
在 proguard-rules.pro 中,您必须以同样的方式指定哪些库会产生重复警告。
效果很好!
关于Android multidex 不支持混淆器,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32537333/