码迷,mamicode.com
首页 > 移动开发 > 详细

Eclipse混淆文件导入Android Studio Gradle编译报input jar file is specified twice

时间:2015-10-26 11:49:45      阅读:204      评论:0      收藏:0      [点我收藏+]

标签:

Eclipse项目中的混淆配置文件 复制到AS中 在混淆的过程中提示如下错误
 
技术分享
 
Error:Execution failed for task ‘:app:proguardDemoRelease‘.
> java.io.IOException: The same input jar [D:\Users\workspace_studio\Test5\app\libs\fastjson.jar] is specified twice. 

 

解决方案:

删除  -libraryjars libs/***.jar from your proguard-rules.pro file.

 

技术分享

原因是build.gradle文件配置了

 

dependencies {     compile fileTree(include: ‘*.jar‘, dir: ‘libs‘)

}

里面已经添加过jar包,混淆文件proguard-rules.pro里面又加了句-libraryjars libs/***.jar,将-libraryjars libs/***.jar 前面用#号注释或者直接删掉即可。

Eclipse混淆文件导入Android Studio Gradle编译报input jar file is specified twice

标签:

原文地址:http://www.cnblogs.com/dongweiq/p/4910680.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!