gpt4 book ai didi

java - Exoplayer 库版本冲突

转载 作者:行者123 更新时间:2023-11-30 00:04:21 25 4
gpt4 key购买 nike

目前,我正在使用 2.3.1 版的 exoplayer 库。我想在同一个项目中包含 exoplayer 2.7.0 版,我们怎样才能做到这一点而不会发生冲突?如果有人有答案,欢迎但请不要关闭我的问题,因为我为主题工作的组织,他们有不同的供应商,所以他们的要求是不同的版本,所以我无法说出我想要这样做的原因。

了解更多信息 https://github.com/google/ExoPlayer/issues/3988

最佳答案

将/constants.gradle 复制到您的项目中:并用这个替换你的 build.gradle 数据:

apply plugin: 'com.android.library'
apply from: '../constants.gradle'

android {
compileSdkVersion project.ext.compileSdkVersion
buildToolsVersion project.ext.buildToolsVersion

defaultConfig {
minSdkVersion project.ext.minSdkVersion
targetSdkVersion project.ext.targetSdkVersion
consumerProguardFiles 'proguard-rules.txt'
}

// Workaround to prevent circular dependency on project :testutils.
sourceSets {
androidTest {
java.srcDirs += "../../testutils/src/main/java/"
}
test {
java.srcDirs += "../../testutils/src/main/java/"
java.srcDirs += "../../testutils_robolectric/src/main/java/"
}
}

buildTypes {
// Re-enable test coverage when the following issue is fixed:
// https://issuetracker.google.com/issues/37019591
// debug {
// testCoverageEnabled = true
// }
}
}

dependencies {
implementation 'com.android.support:support-annotations:' + supportLibraryVersion
androidTestImplementation 'com.google.dexmaker:dexmaker:' + dexmakerVersion
androidTestImplementation 'com.google.dexmaker:dexmaker-mockito:' + dexmakerVersion
androidTestImplementation 'com.google.truth:truth:' + truthVersion
androidTestImplementation 'org.mockito:mockito-core:' + mockitoVersion
testImplementation 'com.google.truth:truth:' + truthVersion
testImplementation 'junit:junit:' + junitVersion
testImplementation 'org.mockito:mockito-core:' + mockitoVersion
testImplementation 'org.robolectric:robolectric:' + robolectricVersion
}

ext {
javadocTitle = 'Core module'
}

ext {
releaseArtifact = 'exoplayer-core'
releaseDescription = 'The ExoPlayer library core module.'
}

关于java - Exoplayer 库版本冲突,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49292359/

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