summaryrefslogtreecommitdiffhomepage
path: root/tunnel/build.gradle.kts
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2023-05-03 14:09:11 +0200
committerJason A. Donenfeld <Jason@zx2c4.com>2023-05-03 14:09:11 +0200
commitdca96a52b4580ebbc888604434dd9ff5d7d37361 (patch)
treeea0911f0975da722ac43f376af8ebb9ac77cab3e /tunnel/build.gradle.kts
parentcf4fca8086858319f1b395c9059c67b436222cbb (diff)
gradle: reabstract package name
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'tunnel/build.gradle.kts')
-rw-r--r--tunnel/build.gradle.kts10
1 files changed, 6 insertions, 4 deletions
diff --git a/tunnel/build.gradle.kts b/tunnel/build.gradle.kts
index 63535199..0922d602 100644
--- a/tunnel/build.gradle.kts
+++ b/tunnel/build.gradle.kts
@@ -1,6 +1,8 @@
@file:Suppress("UnstableApiUsage")
import org.gradle.api.tasks.testing.logging.TestLogEvent
+val pkg: String = providers.gradleProperty("wireguardPackageName").get()
+
plugins {
alias(libs.plugins.android.library)
`maven-publish`
@@ -13,7 +15,7 @@ android {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
- namespace = "com.wireguard.android.tunnel"
+ namespace = "${pkg}.tunnel"
defaultConfig {
minSdk = 21
}
@@ -37,14 +39,14 @@ android {
release {
externalNativeBuild {
cmake {
- arguments("-DANDROID_PACKAGE_NAME=com.wireguard.android")
+ arguments("-DANDROID_PACKAGE_NAME=${pkg}")
}
}
}
debug {
externalNativeBuild {
cmake {
- arguments("-DANDROID_PACKAGE_NAME=com.wireguard.android.debug")
+ arguments("-DANDROID_PACKAGE_NAME=${pkg}.debug")
}
}
}
@@ -74,7 +76,7 @@ dependencies {
publishing {
publications {
register<MavenPublication>("release") {
- groupId = "com.wireguard.android"
+ groupId = pkg
artifactId = "tunnel"
version = providers.gradleProperty("wireguardVersionName").get()
afterEvaluate {