gpt4 book ai didi

java - 找不到支持-v4.aar(com.android.support :support-v4:24. 1.1)

转载 作者:行者123 更新时间:2023-11-29 19:30:06 29 4
gpt4 key购买 nike

该项目是 Github 上的 Google 示例之一,Androidtv-Leanback .我克隆它并使用 Android studio 打开,但构建失败。

错误:

Could not find support-v4.aar(com.android.support:support-v4:24.1.1)

build.gradle:

apply plugin: 'com.android.application'

android {
compileSdkVersion 24
buildToolsVersion '24'
defaultConfig {
applicationId "com.example.android.tvleanback"
minSdkVersion 21
targetSdkVersion 24
versionCode 2
versionName "1.3"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:support-v4:24.1.1'
compile 'com.android.support:recyclerview-v7:24.1.1'
compile 'com.android.support:leanback-v17:24.1.1'
compile 'com.android.support:recommendation:24.1.1'
compile 'com.android.support:preference-leanback-v17:24.1.1'
compile 'com.github.bumptech.glide:glide:3.6.1'
testCompile 'junit:junit:4.12'
testCompile 'org.mockito:mockito-core:1.10.19'
testCompile 'org.robolectric:robolectric:3.1'
androidTestCompile 'com.android.support:support-annotations:24.1.1'
androidTestCompile 'com.android.support.test:runner:0.5'
androidTestCompile 'com.android.support.test:rules:0.5'
compile 'com.google.android.exoplayer:exoplayer:r1.5.8'
// compile files('src/libs/android-support-v4.jar')
}

最佳答案

在您的 build.gradle 文件中添加此依赖项

dependencies {
...
compile "com.android.support:support-v4:24.2.1"
}

并确保您已经使用 sdk 管理器下载了 android 支持存储库。

关于java - 找不到支持-v4.aar(com.android.support :support-v4:24. 1.1),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40212377/

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com