Convert compiler projects to the new intellij deps

This commit is contained in:
Ilya Chernikov
2017-12-08 13:24:45 +01:00
committed by Vyacheslav Gerasimov
parent a418a3ac49
commit 4eb557724c
23 changed files with 49 additions and 232 deletions
+1 -1
View File
@@ -143,7 +143,7 @@ extra["markdownParserRepo"] = "https://teamcity.jetbrains.com/guestAuth/reposito
extra["IntellijCoreDependencies"] =
listOf("annotations.jar",
"asm-all.jar",
"guava-*.jar",
"guava-21.0.jar",
"jdom.jar",
"jna.jar",
"log4j.jar",
@@ -30,7 +30,10 @@ fun Project.intellijCoreDep() = intellijDep("intellij-core")
fun ModuleDependency.includeJars(vararg names: String) {
names.forEach {
artifact { name = it; extension = "jar" }
artifact {
name = it.removeSuffix(".jar")
extension = "jar"
}
}
}
+4 -13
View File
@@ -3,10 +3,6 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("jps-standalone", "jps-build-test")
}
dependencies {
compile(project(":compiler:util"))
compile(project(":compiler:cli"))
@@ -14,6 +10,7 @@ dependencies {
compile(project(":compiler:backend"))
compile(projectTests(":compiler:tests-common"))
compile(commonDep("junit:junit"))
compileOnly(intellijDep()) { includeJars("openapi") }
testCompile(project(":compiler:incremental-compilation-impl"))
testCompile(project(":core:descriptors"))
@@ -21,15 +18,9 @@ dependencies {
testCompile(project(":compiler:frontend.java"))
testCompile(projectTests(":jps-plugin"))
testCompile(commonDep("junit:junit"))
}
afterEvaluate {
dependencies {
compileOnly(intellij { include("openapi.jar") })
testCompile(intellij { include("openapi.jar", "idea.jar", "idea_rt.jar", "groovy-all-*.jar", "jps-builders.jar") })
testCompile(intellijExtra("jps-standalone") { include("jps-model.jar") })
testCompile(intellijExtra("jps-build-test"))
}
testCompile(intellijDep()) { includeJars("openapi", "idea", "idea_rt", "groovy-all-2.4.6", "jps-builders") }
testCompile(intellijDep("jps-standalone")) { includeJars("jps-model") }
testCompile(intellijDep("jps-build-test"))
}
sourceSets {
+1 -10
View File
@@ -3,22 +3,13 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
compile(project(":core:descriptors"))
compile(project(":core:descriptors.jvm"))
compile(project(":compiler:util"))
compile(project(":compiler:frontend"))
compile(project(":compiler:ir.tree"))
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
}
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
}
sourceSets {
+2 -11
View File
@@ -3,10 +3,6 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
compile(project(":compiler:util"))
compile(project(":compiler:backend-common"))
@@ -15,13 +11,8 @@ dependencies {
compile(project(":compiler:ir.tree"))
compile(project(":compiler:ir.psi2ir"))
compile(project(":compiler:serialization"))
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
compileOnly(intellij { include("annotations.jar", "asm-all.jar", "trove4j.jar", "guava-*.jar") })
}
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeJars("annotations", "asm-all", "trove4j", "guava-21.0") }
}
sourceSets {
+3 -17
View File
@@ -6,14 +6,6 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
repositories {
androidDxJarRepo(project)
}
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
val compilerModules: Array<String> by rootProject.extra
val otherCompilerModules = compilerModules.filter { it != path }
@@ -63,11 +55,14 @@ dependencies {
otherCompilerModules.forEach {
testCompileOnly(project(it))
}
testCompileOnly(intellijCoreDep()) { includeJars("intellij-core") }
testCompileOnly(intellijDep()) { includeJars("openapi", "idea", "idea_rt", "util", "asm-all") }
testRuntime(projectDist(":kotlin-reflect"))
testRuntime(projectDist(":kotlin-daemon-client"))
testRuntime(androidDxJar())
testRuntime(files(toolsJar()))
testRuntime(intellijDep())
testJvm6ServerRuntime(projectTests(":compiler:tests-common-jvm6"))
@@ -75,15 +70,6 @@ dependencies {
antLauncherJar(files(toolsJar()))
}
afterEvaluate {
dependencies {
testCompileOnly(intellijCoreJar())
testCompileOnly(intellij { include("openapi.jar", "idea.jar", "idea_rt.jar", "util.jar", "asm-all.jar",
"commons-httpclient-3.1-patched.jar") })
testRuntime(intellij())
}
}
sourceSets {
"main" {}
"test" {
+2 -11
View File
@@ -3,10 +3,6 @@ apply { plugin("kotlin") }
jvmTarget = "1.8"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
compile(project(":compiler:util"))
compile(project(":compiler:cli-common"))
@@ -24,6 +20,8 @@ dependencies {
compile(commonDep("org.fusesource.jansi", "jansi"))
compile(commonDep("org.jline", "jline"))
compile(files("${System.getProperty("java.home")}/../lib/tools.jar"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeIntellijCoreJarDependencies(project) }
testCompile(project(":compiler:backend"))
testCompile(project(":compiler:cli"))
@@ -32,13 +30,6 @@ dependencies {
testCompile(commonDep("junit:junit"))
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
compileOnly(intellijCoreJarDependencies())
}
}
sourceSets {
"main" {
projectDefault()
+2 -11
View File
@@ -3,23 +3,14 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
compile(project(":core:util.runtime"))
compile(project(":compiler:frontend"))
compile(project(":compiler:frontend.java"))
compile(project(":compiler:frontend.script"))
compileOnly(project(":kotlin-reflect-api"))
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
compileOnly(intellijCoreJarDependencies())
}
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeIntellijCoreJarDependencies(project) }
}
sourceSets {
+1 -10
View File
@@ -7,10 +7,6 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
compile(project(":kotlin-build-common"))
compileOnly(project(":compiler:cli-common"))
@@ -19,15 +15,10 @@ dependencies {
compileOnly(project(":compiler:daemon-common"))
compile(project(":kotlin-daemon-client"))
compileOnly(project(":compiler:util"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
runtimeOnly(projectRuntimeJar(":kotlin-compiler-embeddable"))
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
}
}
sourceSets {
"main" { projectDefault() }
"test" {}
@@ -3,10 +3,6 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
val compile by configurations
compile(project(":compiler:cli"))
@@ -15,13 +11,8 @@ dependencies {
compile(project(":kotlin-build-common"))
compile(commonDep("org.fusesource.jansi", "jansi"))
compile(commonDep("org.jline", "jline"))
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
compileOnly(intellijCoreJarDependencies())
}
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeIntellijCoreJarDependencies(project) }
}
sourceSets {
+3 -12
View File
@@ -3,26 +3,17 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
compile(project(":core:util.runtime"))
compile(commonDep("javax.inject"))
compileOnly(project(":kotlin-stdlib"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
testCompile(project(":kotlin-stdlib"))
testCompile(projectDist(":kotlin-test:kotlin-test-jvm"))
testCompile(projectDist(":kotlin-test:kotlin-test-junit"))
testCompile(commonDep("junit:junit"))
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
testCompile(intellijCoreJar())
testRuntime(intellij { include("trove4j.jar") })
}
testCompile(intellijCoreDep()) { includeJars("intellij-core") }
testRuntime(intellijDep()) { includeJars("trove4j") }
}
sourceSets {
+2 -12
View File
@@ -3,25 +3,15 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
val compile by configurations
compile(project(":compiler:cli"))
compile(project(":compiler:daemon-common"))
compile(project(":compiler:incremental-compilation-impl"))
compile(project(":kotlin-build-common"))
compile(commonDep("org.fusesource.jansi", "jansi"))
compile(commonDep("org.jline", "jline"))
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
compileOnly(intellijCoreJarDependencies())
}
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeIntellijCoreJarDependencies(project) }
}
sourceSets {
+2 -11
View File
@@ -3,23 +3,14 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
compile(project(":core:descriptors"))
compile(project(":core:descriptors.jvm"))
compile(project(":compiler:util"))
compile(project(":compiler:cli-common"))
compile(project(":kotlin-stdlib"))
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
compileOnly(intellijCoreJarDependencies())
}
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeIntellijCoreJarDependencies(project) }
}
sourceSets {
+2 -11
View File
@@ -3,22 +3,13 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
compile(project(":core:descriptors"))
compile(project(":core:descriptors.jvm"))
compile(project(":compiler:util"))
compile(project(":compiler:frontend"))
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
compileOnly(intellij { include("annotations.jar", "asm-all.jar", "trove4j.jar", "guava-*.jar") })
}
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeJars("annotations", "asm-all", "trove4j", "guava-21.0") }
}
sourceSets {
+1 -10
View File
@@ -3,22 +3,13 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
compile(project(":compiler:util"))
compile(project(":compiler:frontend"))
compile(projectDist(":kotlin-stdlib"))
compile(projectDist(":kotlin-reflect-api"))
compile(commonDep("org.jetbrains.kotlinx", "kotlinx-coroutines-core")) { isTransitive = false }
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
}
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
}
sourceSets {
+2 -11
View File
@@ -3,10 +3,6 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
val jflexPath by configurations.creating
dependencies {
@@ -17,16 +13,11 @@ dependencies {
compile(project(":compiler:resolution"))
compile(projectDist(":kotlin-script-runtime"))
compile(commonDep("io.javaslang","javaslang"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeJars("annotations", "trove4j", "guava-21.0") }
jflexPath(commonDep("org.jetbrains.intellij.deps.jflex", "jflex"))
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
compileOnly(intellij { include("annotations.jar", "trove4j.jar", "guava-*.jar") })
}
}
sourceSets {
"main" { projectDefault() }
"test" {}
@@ -3,10 +3,6 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
compile(project(":core:descriptors"))
compile(project(":core:descriptors.jvm"))
@@ -16,20 +12,16 @@ dependencies {
compile(project(":compiler:frontend.java"))
compile(project(":compiler:cli"))
compile(project(":kotlin-build-common"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeJars("annotations.jar") }
testCompile(commonDep("junit:junit"))
testCompile(projectDist(":kotlin-test:kotlin-test-junit"))
testCompile(projectDist(":kotlin-stdlib"))
testCompile(projectTests(":kotlin-build-common"))
testCompile(projectTests(":compiler:tests-common"))
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
compileOnly(intellij { include("annotations.jar") })
testCompile(intellijCoreJar())
testCompile(intellij { include("annotations.jar") })
}
testCompile(intellijCoreDep()) { includeJars("intellij-core") }
testCompile(intellijDep()) { includeJars("annotations.jar") }
}
sourceSets {
+1 -10
View File
@@ -2,21 +2,12 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
compile(project(":compiler:util"))
compile(project(":compiler:frontend"))
compile(project(":compiler:backend-common"))
compile(project(":compiler:ir.tree"))
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
}
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
}
sourceSets {
+2 -11
View File
@@ -3,22 +3,13 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
compile(project(":compiler:util"))
compile(project(":compiler:backend"))
compile(project(":compiler:frontend"))
compile(project(":compiler:frontend.java"))
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
compileOnly(intellij { include("annotations.jar", "asm-all.jar", "trove4j.jar", "guava-*.jar") })
}
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeJars("annotations", "asm-all", "trove4j", "guava-21.0") }
}
sourceSets {
+1 -10
View File
@@ -3,19 +3,10 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
compile(project(":compiler:util"))
compile(project(":compiler:frontend"))
}
afterEvaluate {
dependencies {
compileOnly(intellijCoreJar())
}
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
}
sourceSets {
+2 -6
View File
@@ -5,12 +5,8 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin()
afterEvaluate {
dependencies {
compileOnly(intellij { include("asm-all.jar") })
}
dependencies {
compileOnly(intellijDep()) { includeJars("asm-all") }
}
sourceSets {
+1 -8
View File
@@ -3,17 +3,10 @@ apply { plugin("kotlin") }
jvmTarget = "1.6"
configureIntellijPlugin()
dependencies {
compile(project(":compiler:util"))
compile(project(":core:descriptors"))
}
afterEvaluate {
dependencies {
compileOnly(intellij { include("trove4j.jar") })
}
compileOnly(intellijDep()) { includeJars("trove4j") }
}
sourceSets {
+3 -11
View File
@@ -2,21 +2,13 @@ import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
apply { plugin("kotlin") }
configureIntellijPlugin {
setExtraDependencies("intellij-core")
}
dependencies {
testCompile(projectTests(":compiler:tests-common"))
testCompile(projectTests(":compiler"))
testCompileOnly(intellijCoreDep()) { includeJars("intellij-core") }
testCompile(projectTests(":generators:test-generator"))
testRuntime(projectDist(":kotlin-reflect"))
}
afterEvaluate {
dependencies {
testCompileOnly(intellijCoreJar())
testRuntime(intellij())
}
testRuntime(intellijDep())
}
sourceSets {