libsignal-client/libsignal.patch
2022-08-11 16:40:26 -07:00

122 lines
3.7 KiB
Diff

From 77b485c685e4b76401a6f1bed195c2ee3623ccb0 Mon Sep 17 00:00:00 2001
From: signald <nobody@signald.org>
Date: Thu, 11 Aug 2022 16:39:35 -0700
Subject: [PATCH] update build files
---
java/build.gradle | 9 +--------
java/client/build.gradle | 30 ++++++++----------------------
java/settings.gradle | 11 +----------
3 files changed, 10 insertions(+), 40 deletions(-)
diff --git a/java/build.gradle b/java/build.gradle
index 71b67765..cb5acd4a 100644
--- a/java/build.gradle
+++ b/java/build.gradle
@@ -6,7 +6,7 @@ def version_number = "0.19.3"
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..ededcff2 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,12 @@ 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 +81,14 @@ 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