Sergey Vasilinets | 70a2e82 | 2017-11-03 12:20:28 -0700 | [diff] [blame] | 1 | buildscript { |
| 2 | def supportRootFolder = project.projectDir.getParentFile() |
Aurimas Liutikas | 7fa5412 | 2018-01-18 14:13:27 -0800 | [diff] [blame] | 3 | apply from: "unbundled_check.gradle" |
Sergey Vasilinets | 70a2e82 | 2017-11-03 12:20:28 -0700 | [diff] [blame] | 4 | repositories { |
| 5 | maven { |
| 6 | url "${supportRootFolder}/../../prebuilts/tools/common/m2/repository" |
| 7 | } |
Aurimas Liutikas | 7fa5412 | 2018-01-18 14:13:27 -0800 | [diff] [blame] | 8 | if (isUnbundledBuild(supportRootFolder)) { |
| 9 | jcenter() |
| 10 | } |
Sergey Vasilinets | 70a2e82 | 2017-11-03 12:20:28 -0700 | [diff] [blame] | 11 | } |
Sergey Vasilinets | ccb3fcb | 2017-10-16 23:46:48 +0000 | [diff] [blame] | 12 | |
Sergey Vasilinets | 70a2e82 | 2017-11-03 12:20:28 -0700 | [diff] [blame] | 13 | apply from: "build_dependencies.gradle" |
| 14 | |
| 15 | dependencies { |
| 16 | classpath build_libs.kotlin.gradle_plugin |
| 17 | } |
Jake Wharton | 7495cc1 | 2018-01-05 11:05:13 -0500 | [diff] [blame] | 18 | |
| 19 | configurations.classpath.resolutionStrategy { |
| 20 | eachDependency { details -> |
| 21 | if (details.requested.group == 'org.jetbrains.kotlin') { |
| 22 | details.useVersion build_versions.kotlin |
| 23 | } |
| 24 | } |
| 25 | } |
Sergey Vasilinets | 70a2e82 | 2017-11-03 12:20:28 -0700 | [diff] [blame] | 26 | } |
Sergey Vasilinets | 71469cb | 2017-11-17 13:56:50 -0800 | [diff] [blame] | 27 | def runningInBuildServer = System.env.DIST_DIR != null && System.env.OUT_DIR != null |
| 28 | if (runningInBuildServer) { |
| 29 | System.setProperty("kotlin.compiler.execution.strategy", "in-process") |
| 30 | } |
Sergey Vasilinets | 70a2e82 | 2017-11-03 12:20:28 -0700 | [diff] [blame] | 31 | |
| 32 | apply from: "build_dependencies.gradle" |
Aurimas Liutikas | f09d858 | 2017-01-20 21:49:51 -0800 | [diff] [blame] | 33 | |
Aurimas Liutikas | 9ab3b4c | 2017-04-19 09:33:27 -0700 | [diff] [blame] | 34 | ext.supportRootFolder = project.projectDir.getParentFile() |
| 35 | apply from: 'repos.gradle' |
Aurimas Liutikas | 9ab3b4c | 2017-04-19 09:33:27 -0700 | [diff] [blame] | 36 | |
Sergey Vasilinets | ccb3fcb | 2017-10-16 23:46:48 +0000 | [diff] [blame] | 37 | repos.addMavenRepositories(repositories) |
Sergey Vasilinets | bb245e0 | 2017-10-11 00:16:04 -0700 | [diff] [blame] | 38 | |
Sergey Vasilinets | 70a2e82 | 2017-11-03 12:20:28 -0700 | [diff] [blame] | 39 | apply plugin: 'java' |
| 40 | apply plugin: 'kotlin' |
| 41 | |
Aurimas Liutikas | 1ac04ed | 2018-01-08 09:48:19 -0800 | [diff] [blame] | 42 | apply from: "kotlin-dsl-dependency.gradle.kts" |
| 43 | |
Sergey Vasilinets | 70a2e82 | 2017-11-03 12:20:28 -0700 | [diff] [blame] | 44 | compileGroovy { |
| 45 | dependsOn tasks.getByPath('compileKotlin') |
| 46 | classpath += files(compileKotlin.destinationDir) |
| 47 | } |
Aurimas Liutikas | 9697da7 | 2016-12-22 15:50:42 -0800 | [diff] [blame] | 48 | dependencies { |
Sergey Vasilinets | 70a2e82 | 2017-11-03 12:20:28 -0700 | [diff] [blame] | 49 | compile build_libs.gradle |
| 50 | compile build_libs.jacoco |
| 51 | compile build_libs.error_prone |
| 52 | compile build_libs.jarjar_gradle |
Aurimas Liutikas | a192828 | 2017-07-17 12:32:26 -0700 | [diff] [blame] | 53 | compile gradleApi() |
Aurimas Liutikas | ec5894e | 2018-01-02 15:08:37 -0800 | [diff] [blame] | 54 | testCompile "junit:junit:4.12" |
Aurimas Liutikas | 9697da7 | 2016-12-22 15:50:42 -0800 | [diff] [blame] | 55 | } |