X-Git-Url: https://git.nmode.ca/signal-cli/blobdiff_plain/6cb867cbebec69a7652fec0b9e6cb2860e99bcbf..f1d735f93db6ec45b391f4fc6bcd20c486d7143c:/lib/build.gradle.kts diff --git a/lib/build.gradle.kts b/lib/build.gradle.kts index a9b5a95f..dd765cba 100644 --- a/lib/build.gradle.kts +++ b/lib/build.gradle.kts @@ -4,20 +4,32 @@ plugins { } java { - sourceCompatibility = JavaVersion.VERSION_11 - targetCompatibility = JavaVersion.VERSION_11 + sourceCompatibility = JavaVersion.VERSION_17 + targetCompatibility = JavaVersion.VERSION_17 } -repositories { - mavenLocal() - mavenCentral() -} +val libsignalClientPath = project.findProperty("libsignal_client_path")?.toString() dependencies { - api("com.github.turasa:signal-service-java:2.15.3_unofficial_21") - implementation("com.google.protobuf:protobuf-javalite:3.10.0") - implementation("org.bouncycastle:bcprov-jdk15on:1.68") - implementation("org.slf4j:slf4j-api:1.7.30") + if (libsignalClientPath == null) { + implementation(libs.signalservice) + } else { + implementation(libs.signalservice) { + exclude(group = "org.signal", module = "libsignal-client") + } + implementation(files(libsignalClientPath)) + } + implementation(libs.jackson.databind) + implementation(libs.bouncycastle) + implementation(libs.slf4j.api) + implementation(libs.sqlite) + implementation(libs.hikari) + + testImplementation(libs.junit) +} + +tasks.named("test") { + useJUnitPlatform() } configurations { @@ -26,6 +38,17 @@ configurations { } } +tasks.withType().configureEach { + isPreserveFileTimestamps = false + isReproducibleFileOrder = true +} + tasks.withType { options.encoding = "UTF-8" } + +tasks.jar { + manifest { + attributes("Automatic-Module-Name" to "org.asamk.signal.manager") + } +}