错误java.lang.RuntimeException:java.lang.RuntimeException:com.android.builder.dexing.DexArchiveMergerException:无法合并dex
我的项目在Android Studio 3.0.1的Whatchap中,这是我的设计毕业。 build.gradle(应用程序) 应用插件:“com.android.application”错误java.lang.RuntimeException:java.lang.RuntimeException:com.android.builder.dexing.DexArchiveMergerException:无法合并dex,java,android,Java,Android,我的项目在Android Studio 3.0.1的Whatchap中,这是我的设计毕业。 build.gradle(应用程序) 应用插件:“com.android.application” android { compileOptions { sourceCompatibility 1.8 targetCompatibility 1.8 } compileSdkVersion 26 defaultConfig {
android {
compileOptions {
sourceCompatibility 1.8
targetCompatibility 1.8
}
compileSdkVersion 26
defaultConfig {
applicationId "stmik.iax.whatchap"
minSdkVersion 16
targetSdkVersion 26
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
buildToolsVersion '26.0.2'
productFlavors {
}
}
dependencies {
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation 'com.android.support:appcompat-v7:26.1.0'
implementation 'com.android.support.constraint:constraint-layout:1.0.2'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.1'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1'
implementation files('libs/sun.misc.BASE64Decoder.jar')
implementation 'com.android.support:support-v4:26.1.0'
implementation 'com.google.android.gms:play-services-gcm:11.2.0'
}
模梯度
buildscript {
repositories {
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.0.1'
}
}
allprojects {
repositories {
google()
jcenter()
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
这就是我的问题
错误:任务的执行失败
“:app:transformDexArchiveWithExternalLibsDexMergerForDebug”
java.lang.RuntimeException:java.lang.RuntimeException:com.android.builder.dexing.DexArchiveMergerException:无法合并
指数
我一直在努力
1.清洁工程
2.重建项目
添加启用了多索引的true
它不能解决我的问题
java.lang.RuntimeException:java.lang.RuntimeException:
com.android.builder.dexing.DexArchiveMergerException:无法合并
指数
您应该升级gms:play服务版本
implementation 'com.google.android.gms:play-services:11.4.0'
在此之后,清除重建运行
FYI
检查gms:play services的版本。阅读。解决了这个问题吗?让我们通知你。