Build: Fix variant resolution ambiguity
This commit is contained in:
@@ -4,7 +4,13 @@ plugins {
|
||||
kotlin("jvm")
|
||||
}
|
||||
|
||||
val testCompilerClasspath by configurations.creating
|
||||
val testCompilerClasspath by configurations.creating {
|
||||
attributes {
|
||||
attribute(Usage.USAGE_ATTRIBUTE, objects.named(Usage.JAVA_RUNTIME))
|
||||
attribute(Category.CATEGORY_ATTRIBUTE, objects.named(Category.LIBRARY))
|
||||
}
|
||||
}
|
||||
|
||||
val testCompilationClasspath by configurations.creating
|
||||
|
||||
dependencies {
|
||||
|
||||
@@ -11,7 +11,7 @@ dependencies {
|
||||
runtimeOnly(kotlinStdlib())
|
||||
runtimeOnly(project(":kotlin-script-runtime"))
|
||||
runtimeOnly(project(":kotlin-reflect"))
|
||||
runtime(project(":kotlin-daemon-embeddable"))
|
||||
runtimeOnly(project(":kotlin-daemon-embeddable"))
|
||||
runtimeOnly(commonDep("org.jetbrains.intellij.deps", "trove4j"))
|
||||
testCompile(commonDep("junit:junit"))
|
||||
testCompile(project(":kotlin-test:kotlin-test-junit"))
|
||||
|
||||
@@ -40,9 +40,6 @@ val proguardLibraries by configurations.creating {
|
||||
// Libraries to copy to the lib directory
|
||||
val libraries by configurations.creating {
|
||||
exclude("org.jetbrains.kotlin", "kotlin-stdlib-common")
|
||||
attributes {
|
||||
attribute(LibraryElements.LIBRARY_ELEMENTS_ATTRIBUTE, objects.named(LibraryElements.JAR))
|
||||
}
|
||||
}
|
||||
|
||||
val librariesStripVersion by configurations.creating
|
||||
|
||||
@@ -142,7 +142,11 @@ val libraries by configurations.creating {
|
||||
exclude("org.jetbrains.intellij.deps", "trove4j") // Idea already has trove4j
|
||||
}
|
||||
|
||||
val jpsPlugin by configurations.creating
|
||||
val jpsPlugin by configurations.creating {
|
||||
attributes {
|
||||
attribute(LibraryElements.LIBRARY_ELEMENTS_ATTRIBUTE, objects.named(LibraryElements.JAR))
|
||||
}
|
||||
}
|
||||
|
||||
configurations.all {
|
||||
resolutionStrategy {
|
||||
|
||||
@@ -1,28 +1,16 @@
|
||||
|
||||
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
|
||||
import org.gradle.jvm.tasks.Jar
|
||||
|
||||
description = "Kotlin Daemon (for using with embeddable compiler)"
|
||||
|
||||
plugins {
|
||||
`java`
|
||||
}
|
||||
|
||||
val packedJars by configurations.creating
|
||||
|
||||
dependencies {
|
||||
packedJars(project(":kotlin-daemon")) { isTransitive = false }
|
||||
embedded(project(":kotlin-daemon")) { isTransitive = false }
|
||||
}
|
||||
|
||||
publish()
|
||||
|
||||
noDefaultJar()
|
||||
|
||||
runtimeJar(rewriteDepsToShadedCompiler(
|
||||
tasks.register<ShadowJar>("shadowJar") {
|
||||
from(packedJars)
|
||||
}
|
||||
))
|
||||
runtimeJar(rewriteDefaultJarDepsToShadedCompiler())
|
||||
|
||||
sourcesJar()
|
||||
javadocJar()
|
||||
|
||||
Reference in New Issue
Block a user