Diego Vela | 57b06cf | 2021-05-10 10:34:12 -0700 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2021 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 | import androidx.build.LibraryGroups |
| 18 | import androidx.build.LibraryType |
| 19 | import androidx.build.LibraryVersions |
| 20 | import org.jetbrains.kotlin.gradle.tasks.KotlinCompile |
| 21 | |
Diego Vela | 57b06cf | 2021-05-10 10:34:12 -0700 | [diff] [blame] | 22 | plugins { |
| 23 | id("AndroidXPlugin") |
| 24 | id("com.android.library") |
| 25 | id("org.jetbrains.kotlin.android") |
| 26 | } |
| 27 | |
| 28 | android { |
| 29 | defaultConfig { |
| 30 | multiDexEnabled = true |
| 31 | } |
| 32 | } |
| 33 | |
| 34 | dependencies { |
Aurimas Liutikas | fbd9ec6 | 2021-05-24 16:00:39 -0700 | [diff] [blame] | 35 | api(libs.kotlinStdlib) |
| 36 | api(libs.kotlinCoroutinesCore) |
| 37 | api(libs.kotlinCoroutinesRx3) |
| 38 | api(libs.rxjava3) |
Diego Vela | 57b06cf | 2021-05-10 10:34:12 -0700 | [diff] [blame] | 39 | api(project(":window:window")) |
| 40 | |
Aurimas Liutikas | fbd9ec6 | 2021-05-24 16:00:39 -0700 | [diff] [blame] | 41 | androidTestImplementation(libs.testExtJunit) |
| 42 | androidTestImplementation(libs.testRunner) |
| 43 | androidTestImplementation(libs.testRules) |
| 44 | androidTestImplementation(libs.dexmakerMockito, excludes.bytebuddy) |
| 45 | androidTestImplementation(libs.mockitoCore, excludes.bytebuddy) |
| 46 | androidTestImplementation(libs.mockitoKotlin, excludes.bytebuddy) |
| 47 | androidTestImplementation(libs.kotlinCoroutinesTest) |
| 48 | androidTestImplementation(libs.multidex) |
Diego Vela | 57b06cf | 2021-05-10 10:34:12 -0700 | [diff] [blame] | 49 | } |
| 50 | |
| 51 | androidx { |
| 52 | name = "WindowManager RxJava 3 Support" |
| 53 | type = LibraryType.PUBLISHED_LIBRARY |
| 54 | mavenVersion = LibraryVersions.WINDOW |
| 55 | mavenGroup = LibraryGroups.WINDOW |
| 56 | inceptionYear = "2021" |
| 57 | description = "WindowManager RxJava 3 Support" |
| 58 | } |
| 59 | |
| 60 | // Allow usage of Kotlin's @OptIn. |
| 61 | tasks.withType(KotlinCompile).configureEach { |
| 62 | kotlinOptions { |
| 63 | freeCompilerArgs += ["-Xopt-in=kotlin.RequiresOptIn"] |
| 64 | } |
| 65 | } |