简体   繁体   English

实施AAR库后,Android Studio 2.1 Gradle同步错误

[英]Android Studio 2.1 Gradle sync error after implemented AAR library

I have added AAR Library file into Project. 我已经将AAR库文件添加到Project中。 After successfully added, After implementing the aar library into my main code, while gradle sync , am getting these exception.. 成功添加后,在我的主要代码中实现了aar库之后,在gradle sync的同时,出现了这些异常。

Error:Error converting bytecode to dex:
Cause: java.lang.RuntimeException: Exception parsing classes
Error:1 error; aborting
Error:Execution failed for task ':app:transformClassesWithDexForDebug'.
> com.android.build.api.transform.TransformException: java.lang.RuntimeException: com.android.ide.common.process.ProcessException: java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException: Return code 1 for dex process

I have tried Build Clean, Rebuild, Restart to Studio, many times Gradle sync,and Multidex also enabled true getting the above mentioned error. 我尝试了Build Clean,Rebuild,Restart to Studio,多次Gradle sync和Multidex,这也使True真正得到了上述错误。

anyone help me to solve this problem. 任何人都可以帮助我解决这个问题。

Finally I cleared the problem. 最后,我解决了问题。

I have Followed this Steps in Android Studio 2.1: File-Settings-Build,Execution,Deployment select - Instant Run - UnCheck the First Option "Enable Instant Run to hot swap code/resource changes on deploy(default enabled)" 我在Android Studio 2.1中已按照以下步骤操作:文件设置,构建,执行,部署选择-即时运行-取消选中第一个选项“在部署时启用即时运行以热插拔代码/资源更改(默认启用)”

then, finally, Clean and Rebuild and Run the Project. 然后,最后清理并重建并运行该项目。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM