-
Notifications
You must be signed in to change notification settings - Fork 10
/
settings.gradle.kts
42 lines (38 loc) · 1.19 KB
/
settings.gradle.kts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
pluginManagement {
repositories {
google()
gradlePluginPortal()
}
resolutionStrategy {
eachPlugin {
if (requested.id.namespace == "com.android" || requested.id.name == "kotlin-android-extensions") {
useModule("com.android.tools.build:gradle:7.3.1")
}
}
}
}
rootProject.name = "secp256k1-kmp"
// We use a property defined in `local.properties` to know whether we should build the android application or not.
// For example, iOS developers may want to skip that most of the time.
val skipAndroid = File("$rootDir/local.properties").takeIf { it.exists() }
?.inputStream()?.use { java.util.Properties().apply { load(it) } }
?.run { getProperty("skip.android", "false")?.toBoolean() }
?: false
// Use system properties to inject the property in other gradle build files.
System.setProperty("includeAndroid", (!skipAndroid).toString())
include(
":native",
":jni",
":jni:jvm",
":jni:jvm:darwin",
":jni:jvm:linux",
":jni:jvm:mingw",
":jni:jvm:all",
":tests"
)
if (!skipAndroid) {
print("building android library")
include(":jni:android")
} else {
print("skipping android build")
}