Yigit Boyar | 450ed38 | 2017-03-02 09:48:25 -0800 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2017 The Android Open Source Project |
| 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | |
| 17 | def ffLibs |
| 18 | if (hasProperty("libs")) { |
| 19 | ffLibs = libs |
| 20 | } else { |
| 21 | apply from: "${ext.supportRootFolder}/buildSrc/dependencies.gradle" |
| 22 | ffLibs = libs |
| 23 | } |
| 24 | def ffVersions = [:] |
Sergey Vasilinets | 39038d3 | 2017-07-19 17:14:42 -0700 | [diff] [blame] | 25 | ffVersions.kotlin = "1.1.3" |
Yigit Boyar | 450ed38 | 2017-03-02 09:48:25 -0800 | [diff] [blame] | 26 | ffVersions.auto_common = "0.6" |
| 27 | ffVersions.javapoet = "1.8.0" |
Sergey Vasilinets | 0af2c3f | 2017-07-20 12:48:16 -0700 | [diff] [blame] | 28 | ffVersions.compile_testing = "0.11" |
Ian Lake | aea307c | 2017-07-24 15:47:59 -0700 | [diff] [blame] | 29 | ffVersions.support_lib = "26.0.0" |
Yigit Boyar | 450ed38 | 2017-03-02 09:48:25 -0800 | [diff] [blame] | 30 | ffVersions.intellij_annotations = "12.0" |
| 31 | ffVersions.rxjava2 = "2.0.6" |
| 32 | ffVersions.reactivestreams = "1.0.0" |
| 33 | // this Xerial version is newer than we want but we need it to fix |
| 34 | // https://github.com/xerial/sqlite-jdbc/issues/97 |
| 35 | ffVersions.xerial = "3.16.1" |
| 36 | ffVersions.antlr = "4.5.3" |
Yigit Boyar | fa39059 | 2017-03-06 01:31:33 -0800 | [diff] [blame] | 37 | ffVersions.commons_codec = "1.10" |
Yigit Boyar | a64756a | 2017-03-20 17:26:17 -0700 | [diff] [blame] | 38 | ffVersions.gson = "2.8.0" |
Sergey Vasilinets | 0af2c3f | 2017-07-20 12:48:16 -0700 | [diff] [blame] | 39 | ffVersions.guava = "21.0" |
shepshapard | 62693d7 | 2017-08-01 12:48:43 -0700 | [diff] [blame] | 40 | ffVersions.jsr250 = "1.2" |
Yigit Boyar | 450ed38 | 2017-03-02 09:48:25 -0800 | [diff] [blame] | 41 | |
| 42 | ffLibs.kotlin = [ |
| 43 | stdlib : "org.jetbrains.kotlin:kotlin-stdlib:$ffVersions.kotlin", |
| 44 | gradle_plugin : "org.jetbrains.kotlin:kotlin-gradle-plugin:$ffVersions.kotlin" |
| 45 | ] |
| 46 | ffLibs.auto_common = "com.google.auto:auto-common:$ffVersions.auto_common" |
Yigit Boyar | fa39059 | 2017-03-06 01:31:33 -0800 | [diff] [blame] | 47 | ffLibs.apache = [ |
| 48 | commons : [ |
| 49 | codec : "commons-codec:commons-codec:$ffVersions.commons_codec" |
| 50 | ] |
| 51 | ] |
Yigit Boyar | 450ed38 | 2017-03-02 09:48:25 -0800 | [diff] [blame] | 52 | |
| 53 | def getSupportLib(String name, String version, String artifactName = null) { |
| 54 | def sourceProject = findProject(name) |
| 55 | if (sourceProject != null) { |
| 56 | return sourceProject |
| 57 | } |
| 58 | if (artifactName == null) { |
| 59 | artifactName = name |
| 60 | } |
| 61 | return "com.android.support$artifactName:$version" |
| 62 | } |
| 63 | ffLibs.support = [ |
| 64 | annotations : getSupportLib(":support-annotations", ffVersions.support_lib), |
| 65 | core_utils : getSupportLib(':support-core-utils', ffVersions.support_lib), |
| 66 | fragments : getSupportLib(':support-fragment', ffVersions.support_lib), |
Ian Lake | 346607b | 2017-07-24 12:06:30 -0700 | [diff] [blame] | 67 | app_compat : getSupportLib(':appcompat-v7', ffVersions.support_lib), |
| 68 | design : getSupportLib(':design', ffVersions.support_lib), |
| 69 | recyclerview : getSupportLib(':recyclerview-v7', ffVersions.support_lib) |
Yigit Boyar | 450ed38 | 2017-03-02 09:48:25 -0800 | [diff] [blame] | 70 | ] |
| 71 | |
Yigit Boyar | 450ed38 | 2017-03-02 09:48:25 -0800 | [diff] [blame] | 72 | ffLibs.javapoet = "com.squareup:javapoet:$ffVersions.javapoet" |
| 73 | ffLibs.antlr = "org.antlr:antlr4:$ffVersions.antlr" |
| 74 | ffLibs.xerial = "org.xerial:sqlite-jdbc:$ffVersions.xerial" |
| 75 | ffLibs.google_compile_testing = "com.google.testing.compile:compile-testing:$ffVersions.compile_testing" |
| 76 | ffLibs.ij_annotations = "com.intellij:annotations:$ffVersions.intellij_annotations" |
| 77 | ffLibs.reactive_streams = "org.reactivestreams:reactive-streams:$ffVersions.reactivestreams" |
| 78 | ffLibs.rx_java = "io.reactivex.rxjava2:rxjava:$ffVersions.rxjava2" |
Yigit Boyar | a64756a | 2017-03-20 17:26:17 -0700 | [diff] [blame] | 79 | ffLibs.gson = "com.google.code.gson:gson:$ffVersions.gson" |
Sergey Vasilinets | 0af2c3f | 2017-07-20 12:48:16 -0700 | [diff] [blame] | 80 | ffLibs.guava= "com.google.guava:guava:$ffVersions.guava" |
shepshapard | 62693d7 | 2017-08-01 12:48:43 -0700 | [diff] [blame] | 81 | ffLibs.jsr250 = "javax.annotation:javax.annotation-api:$ffVersions.jsr250" |
Yigit Boyar | 450ed38 | 2017-03-02 09:48:25 -0800 | [diff] [blame] | 82 | |
| 83 | ext.tools = [:] |
| 84 | ext.tools.current_sdk = gradle.ext.currentSdk |
| 85 | ext.tools.build_tools_version = rootProject.ext.buildToolsVersion |
| 86 | ext.flatfoot = [:] |
Yigit Boyar | 450ed38 | 2017-03-02 09:48:25 -0800 | [diff] [blame] | 87 | ext.flatfoot.min_sdk = 14 |