[Gradle] Source Dependency Resolver shouldn't check whether project...
...dependency is in current build or not. Because for IDE import it matters that it is a source dependency. While for CLI it is not since included builds will produce an actual klib that will be transformed
This commit is contained in:
committed by
Space Team
parent
ac429b6997
commit
89acfd0a98
+2
-3
@@ -13,7 +13,6 @@ import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSet
|
||||
import org.jetbrains.kotlin.gradle.plugin.ide.IdeDependencyResolver
|
||||
import org.jetbrains.kotlin.gradle.plugin.ide.IdeaKotlinProjectCoordinates
|
||||
import org.jetbrains.kotlin.gradle.plugin.mpp.MetadataDependencyResolution
|
||||
import org.jetbrains.kotlin.gradle.plugin.mpp.projectIdOrNull
|
||||
import org.jetbrains.kotlin.gradle.plugin.sources.DefaultKotlinSourceSet
|
||||
|
||||
internal object IdeVisibleMultiplatformSourceDependencyResolver : IdeDependencyResolver {
|
||||
@@ -25,9 +24,9 @@ internal object IdeVisibleMultiplatformSourceDependencyResolver : IdeDependencyR
|
||||
}
|
||||
|
||||
private fun resolveSourceDependencies(
|
||||
resolution: MetadataDependencyResolution.ChooseVisibleSourceSets,
|
||||
resolution: MetadataDependencyResolution.ChooseVisibleSourceSets
|
||||
): Iterable<IdeaKotlinDependency> {
|
||||
val projectComponentIdentifier = resolution.dependency.projectIdOrNull ?: return emptyList()
|
||||
val projectComponentIdentifier = resolution.dependency.id as? ProjectComponentIdentifier ?: return emptyList()
|
||||
return resolution.allVisibleSourceSetNames.map { visibleSourceSetName ->
|
||||
IdeaKotlinSourceDependency(
|
||||
type = IdeaKotlinSourceDependency.Type.Regular,
|
||||
|
||||
Reference in New Issue
Block a user