From 932a63764730f296ed70e5d5d0aab8efcfe32ef9 Mon Sep 17 00:00:00 2001 From: Ilya Chernikov Date: Thu, 2 Nov 2017 14:31:51 +0100 Subject: [PATCH] Convert jps module to intellij plugin Original commit: 3912025e14c7a86b8957c3a64045ece9afa7d818 --- jps/jps-plugin/build.gradle.kts | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/jps/jps-plugin/build.gradle.kts b/jps/jps-plugin/build.gradle.kts index 70082b729c8..087c98b4cf3 100644 --- a/jps/jps-plugin/build.gradle.kts +++ b/jps/jps-plugin/build.gradle.kts @@ -2,6 +2,10 @@ apply { plugin("kotlin") } val compilerModules: Array by rootProject.extra +configureIntellijPlugin { + setExtraDependencies("intellij-core", "jps-standalone", "jps-build-test") +} + dependencies { compile(project(":kotlin-build-common")) compile(project(":core:descriptors")) @@ -12,14 +16,10 @@ dependencies { compile(project(":compiler:frontend.java")) compile(projectRuntimeJar(":kotlin-preloader")) compile(project(":idea:idea-jps-common")) - compile(ideaSdkDeps("jps-builders", "jps-builders-6", subdir = "jps")) - compile(ideaSdkDeps("jps-model.jar", subdir = "jps")) testCompileOnly(project(":kotlin-reflect-api")) testCompile(project(":compiler:incremental-compilation-impl")) testCompile(projectTests(":compiler:tests-common")) testCompile(projectTests(":compiler:incremental-compilation-impl")) - testCompile(ideaSdkDeps("openapi", "idea")) - testCompileOnly(ideaSdkDeps("jps-build-test", subdir = "jps/test")) testCompile(commonDep("junit:junit")) testCompile(projectDist(":kotlin-test:kotlin-test-jvm")) testCompile(projectTests(":kotlin-build-common")) @@ -27,10 +27,17 @@ dependencies { testRuntime(project(it)) } testRuntime(projectDist(":kotlin-reflect")) - testRuntime(ideaSdkCoreDeps("*.jar")) - testRuntime(ideaSdkDeps("*.jar")) - testRuntime(ideaSdkDeps("*.jar", subdir = "jps/test")) - testRuntime(ideaSdkDeps("*.jar", subdir = "jps")) +} + +afterEvaluate { + dependencies { + compile(intellijExtra("jps-standalone") { include("jps-builders.jar", "jps-builders-6.jar") }) + testCompile(intellij { include("openapi.jar", "idea.jar") }) + testCompile(intellijExtra("jps-build-test")) + testRuntime(intellijCoreJar()) + testRuntime(intellij()) + testRuntime(intellijExtra("jps-standalone")) + } } sourceSets {