【问题标题】:Android dependency errorsAndroid依赖错误
【发布时间】:2020-01-28 03:12:37
【问题描述】:

我在build.gradle中有以下代码

android {
    compileSdkVersion 28
    defaultConfig {
        applicationId "com.example.edit.mapgoogle"
        minSdkVersion 21
        targetSdkVersion 28
        versionCode 1
        versionName "1.0"
        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {


    implementation fileTree(include: ['*.jar'], dir: 'libs')
    implementation 'com.google.android.gms:play-services-maps:17.0.0'
    implementation 'com.android.support:appcompat-v7:28.1.1'
    implementation 'com.android.support:support-v4:28.0.0'
    implementation 'com.android.support.constraint:constraint-layout:1.1.3'
    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'com.android.support.test:runner:1.0.2'
    androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'

}

谁能帮我解决这个问题?

【问题讨论】:

  • 什么问题?那肯定是一堆依赖项。你和他们有问题吗?
  • fix this issue 哪个问题?
  • 'com.android.support:appcompat-v7:28.1.1'存在。

标签: android dependencies build.gradle


【解决方案1】:

这两行没有匹配的支持库版本

implementation 'com.android.support:appcompat-v7:28.1.1'
implementation 'com.android.support:support-v4:28.0.0'

试试这个

implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.android.support:support-v4:28.0.0'

看看这个 stackoverflow link。我确定这与您的问题完全相同。

【讨论】:

  • 不准确。 support-v4:28.0.0 存在。
  • 是的,你是对的。我修好了它。感谢提及。
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2021-10-04
  • 2014-10-18
  • 2017-05-13
  • 2016-05-30
  • 1970-01-01
相关资源
最近更新 更多