'com.google.android.gms'实施GameAnalytics时的冲突

时间:2016-01-14 09:17:26

标签: android twitter-fabric gameanalytics

我收到此错误:

Error:Execution failed for task ':app:processDebugResources'. > Error: more than one library with package name 'com.google.android.gms'

当我尝试通过Fabric实现GameAnalytics时。

这是来自built.gradle文件的snipet

dependencies {
    compile 'com.google.android.gms:play-services-ads:8.4.0'
    compile 'com.android.support:appcompat-v7:23.1.0'
    compile 'com.android.support:support-v4:23.1.0'
    compile('com.gameanalytics.sdk:gameanalytics-android:2.1.0@aar') {
        transitive = true;
    }
}

为什么我会收到此错误?

1 个答案:

答案 0 :(得分:2)

可能GameAnalytics也会实施此服务。

尝试添加:排除组:com.google.android.gms

像这样:

compile('com.gameanalytics.sdk:gameanalytics-android:2.1.0@aar') {
    transitive = true;
    exclude group: 'com.google.android.gms'
}