libsignal-client/libsignal.patch
2022-10-26 20:04:31 -07:00

122 lines
3.7 KiB
Diff

From df2a3fc267457a6f17527ed49e149ccc89895b25 Mon Sep 17 00:00:00 2001
From: signald <nobody@signald.org>
Date: Wed, 26 Oct 2022 20:02:19 -0700
Subject: [PATCH] update build files
---
java/build.gradle | 9 +--------
java/client/build.gradle | 28 ++++++++--------------------
java/settings.gradle | 11 +----------
3 files changed, 10 insertions(+), 38 deletions(-)
diff --git a/java/build.gradle b/java/build.gradle
index 0c8f9458..01d198e7 100644
--- a/java/build.gradle
+++ b/java/build.gradle
@@ -6,7 +6,7 @@ def version_number = "0.20.0"
subprojects {
ext.version_number = version_number
- ext.group_info = "org.signal"
+ ext.group_info = "org.signald"
if (JavaVersion.current().isJava8Compatible()) {
allprojects {
@@ -37,13 +37,6 @@ task makeJniLibrariesDesktop(type:Exec) {
commandLine './build_jni.sh', 'desktop'
}
-task makeAll() {
- group 'Rust'
- description 'Build the native libraries'
-
- dependsOn 'makeJniLibrariesDesktop', 'makeJniLibrariesAndroid'
-}
-
task cargoClean(type:Exec) {
group 'Rust'
commandLine 'cargo', 'clean'
diff --git a/java/client/build.gradle b/java/client/build.gradle
index 7ee6b154..8fa89874 100644
--- a/java/client/build.gradle
+++ b/java/client/build.gradle
@@ -1,7 +1,6 @@
plugins {
id 'java-library'
id 'maven-publish'
- id 'signing'
}
sourceCompatibility = 1.8
@@ -46,23 +45,13 @@ java {
withJavadocJar()
}
-processResources {
- // TODO: Build a different variant of the JNI library for server.
- dependsOn ':makeJniLibrariesDesktop'
- dependsOn ':downloadNonLinuxLibraries'
- gradle.taskGraph.whenReady { graph ->
- if (graph.hasTask(":client:publish")) {
- tasks.getByPath(":downloadNonLinuxLibraries").enabled = true
- }
- }
-}
// MARK: Publishing
publishing {
publications {
mavenJava(MavenPublication) {
- artifactId = archivesBaseName
+ artifactId = archivesBaseName + "-" + System.getenv("TARGET")
from components.java
pom {
@@ -93,16 +82,15 @@ publishing {
}
repositories {
maven {
- url = getReleaseRepositoryUrl()
- credentials {
- username = getRepositoryUsername()
- password = getRepositoryPassword()
+ url System.getenv("CI_API_V4_URL") + "/projects/" + System.getenv("CI_PROJECT_ID") + "/packages/maven"
+ credentials(HttpHeaderCredentials) {
+ name = 'Job-Token'
+ value = System.getenv("CI_JOB_TOKEN")
+ }
+ authentication {
+ header(HttpHeaderAuthentication)
}
}
}
}
-signing {
- required { isReleaseBuild() && gradle.taskGraph.hasTask(":client:publish") }
- sign publishing.publications.mavenJava
-}
diff --git a/java/settings.gradle b/java/settings.gradle
index f6414646..13575990 100644
--- a/java/settings.gradle
+++ b/java/settings.gradle
@@ -6,13 +6,4 @@ pluginManagement {
}
}
-include ':client', ':server'
-
-if (JavaVersion.current().isJava11Compatible()) {
- include ':android'
-} else if (gradle.startParameter.getTaskNames().any { name -> name.contains('android:') }) {
- throw new GradleException("building for Android requires JDK 11 or newer")
-} else if (gradle.startParameter.getTaskNames().any { name -> name.lastIndexOf(':') <= 0 }) {
- // If there are any top-level tasks ("build" or ":build" but not ":client:build")...
- throw new GradleException("building for Android requires JDK 11 or newer; use 'client:' or 'server:' to only build certain products")
-}
+include ':client'
\ No newline at end of file
--
2.30.2