Chris Craik | 55d0f2d | 2018-06-27 13:55:20 -0700 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2018 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 | |
Chris Craik | 55d0f2d | 2018-06-27 13:55:20 -0700 | [diff] [blame] | 17 | import androidx.build.LibraryGroups |
| 18 | import androidx.build.LibraryVersions |
Aurimas Liutikas | 75e93a0 | 2019-05-28 16:31:38 -0700 | [diff] [blame] | 19 | import androidx.build.Publish |
Dustin Lam | befedb9 | 2019-08-16 20:20:41 -0700 | [diff] [blame] | 20 | import org.jetbrains.kotlin.gradle.tasks.KotlinCompile |
| 21 | |
| 22 | import static androidx.build.dependencies.DependenciesKt.* |
Chris Craik | 55d0f2d | 2018-06-27 13:55:20 -0700 | [diff] [blame] | 23 | |
| 24 | plugins { |
Aurimas Liutikas | cdb9f9f | 2019-04-08 12:07:49 +0100 | [diff] [blame] | 25 | id("AndroidXPlugin") |
| 26 | id("com.android.library") |
Chris Craik | 55d0f2d | 2018-06-27 13:55:20 -0700 | [diff] [blame] | 27 | id("kotlin-android") |
| 28 | } |
| 29 | |
| 30 | dependencies { |
Chris Craik | 5412b2c | 2019-04-16 14:45:42 -0700 | [diff] [blame] | 31 | implementation(KOTLIN_STDLIB) |
Dustin Lam | 79d9d24 | 2020-03-30 19:43:53 -0700 | [diff] [blame] | 32 | api("androidx.annotation:annotation:1.1.0") |
| 33 | api("androidx.annotation:annotation-experimental:1.0.0") |
Rahul Ravikumar | 6b603b2 | 2020-03-05 17:18:31 -0800 | [diff] [blame] | 34 | implementation(project(':tracing:tracing-ktx')) |
Chris Craik | 22c3392 | 2019-07-25 12:33:06 -0700 | [diff] [blame] | 35 | implementation(ANDROIDX_TEST_MONITOR) |
Chris Craik | 55d0f2d | 2018-06-27 13:55:20 -0700 | [diff] [blame] | 36 | |
Chris Craik | 22c3392 | 2019-07-25 12:33:06 -0700 | [diff] [blame] | 37 | androidTestImplementation(ANDROIDX_TEST_RULES) |
Chris Craik | 05fc2af | 2019-06-13 09:59:15 -0700 | [diff] [blame] | 38 | androidTestImplementation(ANDROIDX_TEST_EXT_JUNIT) |
Louis Pullen-Freilich | 08e53df | 2019-10-24 20:00:35 +0100 | [diff] [blame] | 39 | androidTestImplementation(KOTLIN_TEST) |
Chris Craik | 55d0f2d | 2018-06-27 13:55:20 -0700 | [diff] [blame] | 40 | } |
| 41 | |
Aurimas Liutikas | 2ad3161 | 2019-04-01 04:23:03 -0700 | [diff] [blame] | 42 | androidx { |
Chris Craik | 22c3392 | 2019-07-25 12:33:06 -0700 | [diff] [blame] | 43 | name = "Android Benchmark Common" |
Aurimas Liutikas | 75e93a0 | 2019-05-28 16:31:38 -0700 | [diff] [blame] | 44 | publish = Publish.SNAPSHOT_AND_RELEASE |
Chris Craik | 55d0f2d | 2018-06-27 13:55:20 -0700 | [diff] [blame] | 45 | mavenGroup = LibraryGroups.BENCHMARK |
| 46 | inceptionYear = "2018" |
Chris Craik | 22c3392 | 2019-07-25 12:33:06 -0700 | [diff] [blame] | 47 | description = "Android Benchmark Common" |
Chris Craik | 55d0f2d | 2018-06-27 13:55:20 -0700 | [diff] [blame] | 48 | } |
Dustin Lam | befedb9 | 2019-08-16 20:20:41 -0700 | [diff] [blame] | 49 | |
| 50 | // Allow usage of Kotlin's @Experimental annotation, which is itself experimental. |
| 51 | tasks.withType(KotlinCompile).configureEach { |
| 52 | kotlinOptions { |
| 53 | freeCompilerArgs += ["-Xuse-experimental=kotlin.Experimental"] |
| 54 | } |
| 55 | } |