1buildscript {
2    def supportRootFolder = project.projectDir.getParentFile()
3    apply from: "unbundled_check.gradle"
4    repositories {
5        maven {
6            url "${supportRootFolder}/../../prebuilts/tools/common/m2/repository"
7        }
8        maven {
9            url "${supportRootFolder}/../../prebuilts/gradle-plugin"
10        }
11        if (isUnbundledBuild(supportRootFolder)) {
12            jcenter()
13        }
14    }
15
16    apply from: "build_dependencies.gradle"
17
18    dependencies {
19        classpath build_libs.kotlin.gradle_plugin
20    }
21
22    configurations.classpath.resolutionStrategy {
23        eachDependency { details ->
24            if (details.requested.group == 'org.jetbrains.kotlin') {
25                details.useVersion build_versions.kotlin
26            }
27        }
28    }
29}
30def runningInBuildServer = System.env.DIST_DIR != null && System.env.OUT_DIR != null
31if (runningInBuildServer) {
32    System.setProperty("kotlin.compiler.execution.strategy", "in-process")
33}
34
35ext.supportRootFolder = project.projectDir.getParentFile()
36apply from: 'repos.gradle'
37apply from: "build_dependencies.gradle"
38apply plugin: "kotlin"
39apply from: "kotlin-dsl-dependency.gradle.kts"
40
41repos.addMavenRepositories(repositories)
42
43dependencies {
44    compile build_libs.gradle
45    compile build_libs.jacoco
46    compile build_libs.error_prone_gradle
47    compile build_libs.jarjar_gradle
48    compile gradleApi()
49    testCompile "junit:junit:4.12"
50}
51
52