在用更新的.aar替换 .aar 库后,我遇到了这个问题。
logcat的
错误:任务':app:transformClassesWithJarMergingForDebug'执行失败。 com.android.build.api.transform.TransformException:java.util.zip.ZipException:重复条目:bolts / AggregateException.class
这是我的gradle代码。
buildscript {
repositories {
maven { url 'https://maven.fabric.io/public' }
}
dependencies {
classpath 'io.fabric.tools:gradle:1.+'
}
}
apply plugin: 'com.android.application'
apply plugin: 'io.fabric'
repositories {
maven { url 'https://maven.fabric.io/public' }
}
android {
compileSdkVersion 23
buildToolsVersion '23.0.1'
defaultConfig {
applicationId "--Package-- Name--"
minSdkVersion 16
targetSdkVersion 22
versionCode 1
versionName "0.0.5"
multiDexEnabled true
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
packagingOptions {
exclude 'META-INF/DEPENDENCIES.txt'
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/NOTICE.txt'
exclude 'META-INF/NOTICE'
exclude 'META-INF/LICENSE'
exclude 'META-INF/DEPENDENCIES'
exclude 'META-INF/notice.txt'
exclude 'META-INF/license.txt'
exclude 'META-INF/dependencies.txt'
exclude 'META-INF/LGPL2.1'
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile('com.twitter.sdk.android:twitter:1.12.1@aar') {
transitive = true;
}
compile project(':cometchat-sdk')
compile 'com.android.support:appcompat-v7:23.4.0'
compile 'com.android.support:design:23.4.0'
compile 'com.android.support:support-v4:23.4.0'
compile 'com.android.support:multidex:1.0.0'
compile 'com.android.support:recyclerview-v7:23.4.0'
compile 'com.github.bumptech.glide:glide:3.7.0'
compile 'com.mikhaellopez:circularimageview:3.0.1'
compile 'com.android.support:cardview-v7:23.4.0'
compile 'com.facebook.android:facebook-android-sdk:4.8.0'
compile 'com.google.android.gms:play-services-plus:9.0.1'
compile 'com.yqritc:recyclerview-flexibledivider:1.2.9'
compile 'com.loopj.android:android-async-http:1.4.9'
compile 'com.google.android.gms:play-services-location:9.0.1'
compile 'com.google.android.gms:play-services-gcm:9.0.1'
compile 'com.github.eneim:Toro:1.2.0'
compile 'com.pnikosis:materialish-progress:1.5'
compile 'com.mcxiaoke.volley:library:1.0.17'
compile 'org.jsoup:jsoup:1.8.1'
compile 'org.apache.httpcomponents:httpcore:4.3.2'
compile 'org.apache.httpcomponents:httpmime:4.3.3'
compile 'com.parse.bolts:bolts-tasks:1.4.0'
compile 'com.android.support.constraint:constraint-layout:1.0.0-alpha1'
compile 'com.readystatesoftware.sqliteasset:sqliteassethelper:+'
testCompile 'junit:junit:4.12'
}