Gradle error “Attribute ”xxx“ has already been defined” in Android Studio

前端 未结 2 1319
野性不改
野性不改 2020-12-08 06:54

I created a project in Android Studio and added a few dependencies using Maven Central and when I try to compile, I run into this type of errors:

Error:Gradl         


        
相关标签:
2条回答
  • 2020-12-08 07:10

    The last version of Google Play Services now uses appcompat-v7, so u can't use it with actionbarsherlock. You have to use only appcompat-v7 or the previous version of play services:

    compile 'com.google.android.gms:play-services:7.0.0'
    
    0 讨论(0)
  • 2020-12-08 07:24

    You should remove this line in your dependencies :

    compile 'com.android.support:appcompat-v7:18.0.0'
    
    0 讨论(0)
提交回复
热议问题