任务应用程序的执行失败:transformClassesAndResourcesWithProguardForDebug [英] Execution failed for task app:transformClassesAndResourcesWithProguardForDebug
本文介绍了任务应用程序的执行失败:transformClassesAndResourcesWithProguardForDebug的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
当我尝试运行我的应用程序时,出现以下错误:
when i try to run my app i get these errors:
Error:Execution failed for task ':app:transformClassesAndResourcesWithProguardForDebug'.
java.io.IOException:请首先更正以上警告.
java.io.IOException: Please correct the above warnings first.
This is my Gradle file
apply plugin: 'com.android.application'
android {
compileSdkVersion 24
buildToolsVersion "24.0.2"
defaultConfig {
applicationId "xxxxxxxxxxxxx"
minSdkVersion 14
targetSdkVersion 24
versionCode 1
versionName "1.0"
}
buildTypes {
release {
minifyEnabled true
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
debug {
minifyEnabled true
shrinkResources true
}
}
}
repositories {
mavenCentral()
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile 'junit:junit:4.12'
compile 'com.android.support:appcompat-v7:24.2.1'
compile 'com.android.support:design:24.2.1'
compile 'com.google.android.gms:play-services:9.8.00'
compile 'com.google.android.gms:play-services-auth:9.8.00'
compile 'com.facebook.android:facebook-android-sdk:4.0.0'
compile 'com.google.android.gms:play-services-ads:9.8.00'
compile 'com.firebase:firebase-client-android:2.3.1'
compile 'com.google.android.gms:play-services-gcm:9.8.00'
}
apply plugin: 'com.google.gms.google-services'
有人可以说为什么我会收到此错误吗?
can any one say why am i getting this error?
它显示了一些jar文件是重复的,但是我不知道要删除哪个依赖项.
it shows some jar files are duplicate ,but i dont know which dependency to remove.
推荐答案
将以下内容添加到您的ProGuard规则中
add the below to your ProGuard rules
-ignorewarnings
这篇关于任务应用程序的执行失败:transformClassesAndResourcesWithProguardForDebug的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文