| author | Da Risk <da_risk@geekorum.com> |
| Mon, 26 May 2025 18:27:07 -0400 | |
| changeset 107 | 627dd879e3a4 |
| parent 106 | e121390a16d3 |
| permissions | -rw-r--r-- |
| 12 | 1 |
/* |
2 |
* AboutOss is an utility library to retrieve and display |
|
3 |
* opensource licenses in Android applications. |
|
4 |
* |
|
|
34
ce299aacc068
build: update license headers
Da Risk <da_risk@geekorum.com>
parents:
29
diff
changeset
|
5 |
* Copyright (C) 2023-2025 by Frederic-Charles Barthelery. |
| 12 | 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 |
*/ |
|
|
74
57d9068de0ef
build: add dokka aggregation project
Da Risk <da_risk@geekorum.com>
parents:
72
diff
changeset
|
22 |
|
| 0 | 23 |
plugins {
|
|
86
ed5dfac18c84
build: use convention plugins to simplify build scripts
Da Risk <da_risk@geekorum.com>
parents:
74
diff
changeset
|
24 |
id("com.geekorum.build.conventions.mpp-library-with-android")
|
|
72
746669e015f9
build: cleanup libs.versions.toml
Da Risk <da_risk@geekorum.com>
parents:
68
diff
changeset
|
25 |
alias(libs.plugins.kotlinx.serialization) |
|
68
f6133d9381b2
build: configure maven publishing using gradle maven publish plugin
Da Risk <da_risk@geekorum.com>
parents:
35
diff
changeset
|
26 |
id("com.geekorum.build.maven-publish")
|
|
74
57d9068de0ef
build: add dokka aggregation project
Da Risk <da_risk@geekorum.com>
parents:
72
diff
changeset
|
27 |
id("com.geekorum.build.dokka")
|
| 0 | 28 |
} |
29 |
||
|
24
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
30 |
kotlin {
|
|
106
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
31 |
androidLibrary {
|
|
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
32 |
namespace = "com.geekorum.aboutoss.core" |
|
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
33 |
withHostTestBuilder { }
|
|
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
34 |
withDeviceTestBuilder { }
|
|
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
35 |
} |
|
24
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
36 |
|
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
37 |
jvm("desktop")
|
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
38 |
|
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
39 |
listOf( |
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
40 |
iosX64(), |
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
41 |
iosArm64(), |
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
42 |
iosSimulatorArm64(), |
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
43 |
).forEach { iosTarget ->
|
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
44 |
iosTarget.binaries.framework {
|
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
45 |
baseName = "aboutoss-core" |
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
46 |
isStatic = true |
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
47 |
} |
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
48 |
} |
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
49 |
|
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
50 |
sourceSets {
|
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
51 |
commonMain.dependencies {
|
|
35
4ca4a17fe9f7
core: change rename main folder sourcesets to androidMain
Da Risk <da_risk@geekorum.com>
parents:
34
diff
changeset
|
52 |
api(libs.okio) |
|
4ca4a17fe9f7
core: change rename main folder sourcesets to androidMain
Da Risk <da_risk@geekorum.com>
parents:
34
diff
changeset
|
53 |
api(libs.kotlinx.coroutines) |
|
28
19cf2e8a0627
core: add LicenseeLicenseInfoRepository
Da Risk <da_risk@geekorum.com>
parents:
24
diff
changeset
|
54 |
implementation(libs.kotlinx.serialization.json) |
|
24
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
55 |
} |
|
106
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
56 |
named("androidHostTest") {
|
|
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
57 |
dependencies {
|
|
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
58 |
implementation(libs.junit) |
|
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
59 |
} |
|
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
60 |
} |
|
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
61 |
named("androidDeviceTest") {
|
|
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
62 |
dependencies {
|
|
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
63 |
implementation(libs.androidx.test.ext.junit) |
|
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
64 |
implementation(libs.espresso.core) |
|
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
65 |
} |
|
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
66 |
} |
|
24
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
67 |
} |
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
68 |
} |
|
f07de07b90c4
core: port OssLicenseParser to multiplatform
Da Risk <da_risk@geekorum.com>
parents:
22
diff
changeset
|
69 |
|
|
106
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
70 |
/* |
| 0 | 71 |
android {
|
72 |
namespace = "com.geekorum.aboutoss.core" |
|
73 |
||
74 |
defaultConfig {
|
|
75 |
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner" |
|
76 |
consumerProguardFiles("consumer-rules.pro")
|
|
77 |
} |
|
78 |
||
79 |
buildTypes {
|
|
80 |
release {
|
|
81 |
isMinifyEnabled = false |
|
82 |
proguardFiles( |
|
83 |
getDefaultProguardFile("proguard-android-optimize.txt"),
|
|
84 |
"proguard-rules.pro" |
|
85 |
) |
|
86 |
} |
|
87 |
} |
|
|
7
b3b2e88f441f
add README.md and maven publications
Da Risk <da_risk@geekorum.com>
parents:
6
diff
changeset
|
88 |
|
|
b3b2e88f441f
add README.md and maven publications
Da Risk <da_risk@geekorum.com>
parents:
6
diff
changeset
|
89 |
publishing {
|
|
b3b2e88f441f
add README.md and maven publications
Da Risk <da_risk@geekorum.com>
parents:
6
diff
changeset
|
90 |
singleVariant("release") {
|
|
b3b2e88f441f
add README.md and maven publications
Da Risk <da_risk@geekorum.com>
parents:
6
diff
changeset
|
91 |
withJavadocJar() |
|
b3b2e88f441f
add README.md and maven publications
Da Risk <da_risk@geekorum.com>
parents:
6
diff
changeset
|
92 |
withSourcesJar() |
|
b3b2e88f441f
add README.md and maven publications
Da Risk <da_risk@geekorum.com>
parents:
6
diff
changeset
|
93 |
} |
|
b3b2e88f441f
add README.md and maven publications
Da Risk <da_risk@geekorum.com>
parents:
6
diff
changeset
|
94 |
} |
| 0 | 95 |
} |
|
106
e121390a16d3
build: use new kotlin android multiplatform library plugin
Da Risk <da_risk@geekorum.com>
parents:
86
diff
changeset
|
96 |
*/ |
| 0 | 97 |
|
|
7
b3b2e88f441f
add README.md and maven publications
Da Risk <da_risk@geekorum.com>
parents:
6
diff
changeset
|
98 |
|
|
68
f6133d9381b2
build: configure maven publishing using gradle maven publish plugin
Da Risk <da_risk@geekorum.com>
parents:
35
diff
changeset
|
99 |
mavenPublishing {
|
|
f6133d9381b2
build: configure maven publishing using gradle maven publish plugin
Da Risk <da_risk@geekorum.com>
parents:
35
diff
changeset
|
100 |
coordinates(groupId = group.toString(), name, version.toString()) |
|
f6133d9381b2
build: configure maven publishing using gradle maven publish plugin
Da Risk <da_risk@geekorum.com>
parents:
35
diff
changeset
|
101 |
} |
|
7
b3b2e88f441f
add README.md and maven publications
Da Risk <da_risk@geekorum.com>
parents:
6
diff
changeset
|
102 |