gpt4 book ai didi

java - android gradle packageAllDebugClassesForMultiDex

转载 作者:行者123 更新时间:2023-12-03 06:25:52 25 4
gpt4 key购买 nike

我尝试使用proguard,但收到gradle错误。
请帮助我确定错误并解决。我如何从buid dex中排除重复项。

* What went wrong: Execution failed for task ':DEESVOC_FREE:packageAllDebugClassesForMultiDex'.

java.util.zip.ZipException: duplicate entry: com/google/api/client/googleapis/extensions/android/accounts/package-info.class



build.gradle
apply plugin: 'com.android.library'

android {
compileSdkVersion 22
buildToolsVersion "22.0.1"

defaultConfig {
minSdkVersion 9
multiDexEnabled true
renderscriptTargetApi 22
renderscriptSupportModeEnabled true
targetSdkVersion 21
}

buildTypes {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
}
}

sourceSets {
main {
manifest.srcFile 'AndroidManifest.xml'
java.srcDirs = ['src']
resources.srcDirs = ['src']
aidl.srcDirs = ['src']
renderscript.srcDirs = ['src']
res.srcDirs = ['res']
jniLibs.srcDirs = ['ndk']
assets.srcDirs = ['assets']
}
}

lintOptions {
checkReleaseBuilds false
abortOnError false
}
}
afterEvaluate {
tasks.matching {
it.name.startsWith('dex')
}.each { dx ->
if (dx.additionalParameters == null) {
dx.additionalParameters = ['--multi-dex']
} else {
dx.additionalParameters += '--multi-dex'
}
}
}

repositories {
jcenter()
}

dependencies {
compile 'com.android.support:appcompat-v7:22.2.1'
compile 'com.google.code.gson:gson:2.3'
// compile 'com.google.guava:guava:18.0'
compile 'com.android.support:multidex:1.0.1'
compile 'com.google.android.gms:play-services-base:7.8.0'
compile 'com.google.android.gms:play-services-analytics:7.8.0'
compile 'com.google.android.gms:play-services-drive:7.8.0'

compile files('libs/renderscript-v8.jar')
compile files('libs/android-async-http-1.4.6.jar')
compile files('libs/gdata-client-1.0.jar')
compile files('libs/gdata-core-1.0.jar')
compile files('libs/gdata-spreadsheet-3.0.jar')
compile files('libs/google-api-client-1.19.1.jar')
compile files('libs/google-api-client-android-1.19.1.jar')
compile files('libs/google-http-client-1.19.0.jar')
compile files('libs/google-http-client-android-1.19.0.jar')
compile files('libs/jackson-core-2.1.3.jar')
compile files('libs/jsr305-1.3.9.jar')
compile files('libs/ormlite-android-4.49-SNAPSHOT.jar')
compile files('libs/ormlite-core-4.49-SNAPSHOT.jar')
compile files('libs/sqlite4java.jar')

compile 'com.nhaarman.supertooltips:library:3.0.0'
compile 'com.parse.bolts:bolts-android:1.2.1'
compile 'com.apptentive:apptentive-android:1.7.4@aar'

compile fileTree(dir: 'parse_libs', include: 'Parse-*.jar')
}

最佳答案

请尝试清洁,对我有用

关于java - android gradle packageAllDebugClassesForMultiDex,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32777477/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com