当我同时使用以下两个库时,我会在构建部分看到错误
implementation 'com.github.AbedElazizShe:LightCompressor:0.5.0'
implementation 'com.github.AndroidDeveloperLB:VideoTrimmer:6'
但是,如果我对这些库中的任何一个进行评论,那么一切都可以正常工作 我该如何解决这个问题?
Execution failed for task ':app:checkDebugDuplicateClasses'.
> 1 exception was raised by workers:
java.lang.RuntimeException: Duplicate class com.coremedia.iso.AbstractBoxParser found in modulesLightCompressor-0.5.0-runtime.jar (com.github.AbedElazizShe:LightCompressor:0.5.0) and isoparser-1.1.22.jar (com.googlecode.mp4parser:isoparser:1.1.22)
Duplicate class com.googlecode.mp4parser.authoring.tracks.SilenceTrackImpl found in modules LightCompressor-0.5.0-runtime.jar (com.github.AbedElazizShe:LightCompressor:0.5.0) and isoparser-1.1.22.jar (com.googlecode.mp4parser:isoparser:1.1.22)
Duplicate class com.googlecode.mp4parser.authoring.tracks.TextTrackImpl$Line found in modules LightCompressor-0.5.0-runtime.jar (com.github.AbedElazizShe:LightCompressor:0.5.0) and isoparser-1.1.22.jar (com.googlecode.mp4parser:isoparser:1.1.22)
Duplicate class com.googlecode.mp4parser.authoring.tracks.h265.H265TrackImpl found in modules LightCompressor-0.5.0-runtime.jar (com.github.AbedElazizShe:LightCompressor:0.5.0) and isoparser-1.1.22.jar (com.googlecode.mp4parser:isoparser:1.1.22)
Duplicate class com.googlecode.mp4parser.authoring.tracks.h265.PicTiming found in modules LightCompressor-0.5.0-runtime.jar (com.github.AbedElazizShe:LightCompressor:0.5.0) and isoparser-1.1.22.jar (com.googlecode.mp4parser:isoparser:1.1.22)
Duplicate class com.googlecode.mp4parser.authoring.tracks.h265.SEIMessage found in modules LightCompressor-0.5.0-runtime.jar (com.github.AbedElazizShe:LightCompressor:0.5.0) and isoparser-1.1.22.jar (com.googlecode.mp4parser:isoparser:1.1.22)
Duplicate class com.googlecode.mp4parser.authoring.tracks.h265.SequenceParameterSetRbsp found in modules LightCompressor-0.5.0-runtime.jar (com.github.AbedElazizShe:LightCompressor:0.5.0) and isoparser-1.1.22.jar (com.googlecode.mp4parser:isoparser:1.1.22)
Duplicate class com.googlecode.mp4parser.authoring.tracks.h265.VideoParameterSet found in modules LightCompressor-0.5.0-runtime.jar (com.github.AbedElazizShe:LightCompressor:0.5.0) and isoparser-1.1.22.jar (com.googlecode.mp4parser:isoparser:1.1.22)
build.gradle(Module:app):
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
android {
compileSdkVersion 29
buildToolsVersion "29.0.1"
defaultConfig {
applicationId "abr.sport.temp"
minSdkVersion 21
targetSdkVersion 29
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation 'androidx.appcompat:appcompat:1.0.2'
implementation 'androidx.core:core-ktx:1.0.2'
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
implementation 'com.github.AbedElazizShe:LightCompressor:0.6.0'
implementation 'com.github.AndroidDeveloperLB:VideoTrimmer:6'
}