| import org.jetbrains.kotlin.UtilsKt |
| |
| def kotlinRoot = ext.properties.containsKey("rootBuildDirectory") ? file("${ext.rootBuildDirectory}/..") : rootProject.projectDir |
| File versionPropertiesFile = new File(kotlinRoot, "gradle/versions.properties") |
| def versionProperties = new Properties() |
| versionPropertiesFile.withInputStream { |
| versionProperties.load(it) |
| } |
| |
| project.buildscript.configurations.all { |
| resolutionStrategy.eachDependency { |
| if (requested.group == "com.google.code.gson" && requested.name == "gson") { |
| useVersion(versionProperties['versions.gson']) |
| because("Force using same gson version because of https://github.com/google/gson/pull/1991") |
| } |
| } |
| } |
| |
| configurations { |
| kotlinCompilerClasspath |
| } |
| |
| if (!(project.findProperty("withoutEmbedabble")?.toString()?.toBoolean() ?: false)) { |
| project.dependencies { |
| kotlinCompilerClasspath(project(":kotlin-compiler-embeddable")) |
| } |
| } |