|
1 /* |
|
2 * AboutOss is an utility library to retrieve and display |
|
3 * opensource licenses in Android applications. |
|
4 * |
|
5 * Copyright (C) 2023-2025 by Frederic-Charles Barthelery. |
|
6 * |
|
7 * This file is part of AboutOss. |
|
8 * |
|
9 * AboutOss is free software: you can redistribute it and/or modify |
|
10 * it under the terms of the GNU General Public License as published by |
|
11 * the Free Software Foundation, either version 3 of the License, or |
|
12 * (at your option) any later version. |
|
13 * |
|
14 * AboutOss is distributed in the hope that it will be useful, |
|
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
17 * GNU General Public License for more details. |
|
18 * |
|
19 * You should have received a copy of the GNU General Public License |
|
20 * along with AboutOss. If not, see <http://www.gnu.org/licenses/>. |
|
21 */ |
|
22 import org.jetbrains.kotlin.gradle.dsl.JvmTarget |
|
23 |
|
24 @Suppress("DSL_SCOPE_VIOLATION") // TODO: Remove once KTIJ-19369 is fixed |
|
25 plugins { |
|
26 id("com.android.application") |
|
27 id("com.geekorum.build.source-license-checker") |
|
28 alias(libs.plugins.kotlin.compose) |
|
29 alias(libs.plugins.jetbrains.compose.multiplatform) |
|
30 alias(libs.plugins.kotlinx.serialization) |
|
31 alias(libs.plugins.google.gms.oss.license) |
|
32 } |
|
33 |
|
34 // workaround bug https://issuetracker.google.com/issues/275534543 |
|
35 buildscript { |
|
36 dependencies { |
|
37 classpath("com.android.tools.build:gradle:9.2.0") |
|
38 } |
|
39 } |
|
40 |
|
41 android { |
|
42 namespace = "com.geekorum.aboutoss.sampleapp.android" |
|
43 |
|
44 compileSdk { |
|
45 version = release(37) |
|
46 } |
|
47 defaultConfig { |
|
48 applicationId = "com.geekorum.aboutoss.sampleapp" |
|
49 minSdk = 28 |
|
50 targetSdk = 35 |
|
51 versionCode = 1 |
|
52 versionName = "1.0" |
|
53 |
|
54 testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner" |
|
55 vectorDrawables { |
|
56 useSupportLibrary = true |
|
57 } |
|
58 } |
|
59 |
|
60 buildTypes { |
|
61 release { |
|
62 isMinifyEnabled = false |
|
63 proguardFiles( |
|
64 getDefaultProguardFile("proguard-android-optimize.txt"), |
|
65 "proguard-rules.pro" |
|
66 ) |
|
67 } |
|
68 } |
|
69 compileOptions { |
|
70 sourceCompatibility = JavaVersion.VERSION_17 |
|
71 targetCompatibility = JavaVersion.VERSION_17 |
|
72 } |
|
73 |
|
74 buildFeatures { |
|
75 compose = true |
|
76 buildConfig = true |
|
77 } |
|
78 packaging { |
|
79 resources { |
|
80 excludes += "/META-INF/{AL2.0,LGPL2.1}" |
|
81 } |
|
82 } |
|
83 } |
|
84 |
|
85 dependencies { |
|
86 implementation(project(":sample")) |
|
87 implementation(compose.material3) |
|
88 implementation(compose.components.resources) |
|
89 implementation(compose.components.uiToolingPreview) |
|
90 implementation(libs.jetbrains.androidx.lifecycle.viewModelCompose) |
|
91 api(libs.androidx.activity) |
|
92 implementation(dependencies.enforcedPlatform(libs.androidx.compose.bom)) |
|
93 implementation(libs.androidx.activity.compose) |
|
94 implementation(libs.geekdroid) |
|
95 |
|
96 testImplementation(libs.junit) |
|
97 androidTestImplementation(libs.androidx.test.ext.junit) |
|
98 androidTestImplementation(libs.espresso.core) |
|
99 androidTestImplementation(platform(libs.androidx.compose.bom)) |
|
100 androidTestImplementation(libs.androidx.compose.uiTestJunit4) |
|
101 debugImplementation(libs.androidx.compose.uiTooling) |
|
102 debugImplementation(libs.androidx.compose.uiTestManifest) |
|
103 } |