xref: /aosp_15_r20/external/dagger2/javatests/artifacts/hilt-android/simple/feature/build.gradle (revision f585d8a307d0621d6060bd7e80091fdcbf94fe27)
1/*
2 * Copyright (C) 2020 The Dagger Authors.
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
17apply plugin: 'com.android.library'
18apply plugin: 'kotlin-android'
19apply plugin: 'kotlin-kapt'
20apply plugin: 'com.google.dagger.hilt.android'
21
22android {
23    compileSdkVersion 33
24    buildToolsVersion "33.0.0"
25
26    defaultConfig {
27        minSdkVersion 16
28        targetSdkVersion 33
29        versionCode 1
30        versionName "1.0"
31    }
32    compileOptions {
33        sourceCompatibility JavaVersion.VERSION_11
34        targetCompatibility JavaVersion.VERSION_11
35    }
36    flavorDimensions "tier"
37    productFlavors {
38        free {
39            dimension "tier"
40        }
41        premium {
42            dimension "tier"
43        }
44    }
45}
46
47kapt {
48 correctErrorTypes true
49}
50
51hilt {
52    enableTransformForLocalTests = true
53}
54
55dependencies {
56    // This is api instead of implementation since Kotlin modules here consumed
57    // by the app need to expose @kotlin.Metadata
58    api "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
59
60    implementation project(":deep-android-lib")
61    implementation project(":deep-lib")
62
63    implementation 'androidx.appcompat:appcompat:1.2.0'
64    implementation "com.google.dagger:hilt-android:$dagger_version"
65    kapt "com.google.dagger:hilt-compiler:$dagger_version"
66}
67