parent
b7ea13261a
commit
b60a810408
1 changed files with 7 additions and 7 deletions
|
@ -1,13 +1,13 @@
|
|||
{ stdenv, lib, fetchurl, makeWrapper, openjdk17_headless, libmatthew_java, dbus, dbus_java }:
|
||||
{ stdenv, lib, fetchurl, makeWrapper, openjdk21_headless, libmatthew_java, dbus, dbus_java }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "signal-cli";
|
||||
version = "0.12.8";
|
||||
version = "0.13.2";
|
||||
|
||||
# Building from source would be preferred, but is much more involved.
|
||||
src = fetchurl {
|
||||
url = "https://github.com/AsamK/signal-cli/releases/download/v${version}/signal-cli-${version}.tar.gz";
|
||||
hash = "sha256-jBz1D1Uz3z+QYj+zAOrbSIkZZeKWSwU3/pHI+sDjJHw=";
|
||||
hash = "sha256-5+pIkRdcFWTNmsSN2tHSy6XMQfUpGSddGsdw5guWzjA=";
|
||||
};
|
||||
|
||||
buildInputs = lib.optionals stdenv.isLinux [ libmatthew_java dbus dbus_java ];
|
||||
|
@ -18,15 +18,15 @@ stdenv.mkDerivation rec {
|
|||
cp -r lib $out/lib
|
||||
cp bin/signal-cli $out/bin/signal-cli
|
||||
'' + (if stdenv.isLinux then ''
|
||||
makeWrapper ${openjdk17_headless}/bin/java $out/bin/signal-cli \
|
||||
--set JAVA_HOME "${openjdk17_headless}" \
|
||||
makeWrapper ${openjdk21_headless}/bin/java $out/bin/signal-cli \
|
||||
--set JAVA_HOME "${openjdk21_headless}" \
|
||||
--add-flags "-classpath '$out/lib/*:${libmatthew_java}/lib/jni'" \
|
||||
--add-flags "-Djava.library.path=${libmatthew_java}/lib/jni:${dbus_java}/share/java/dbus:$out/lib" \
|
||||
--add-flags "org.asamk.signal.Main"
|
||||
'' else ''
|
||||
wrapProgram $out/bin/signal-cli \
|
||||
--prefix PATH : ${lib.makeBinPath [ openjdk17_headless ]} \
|
||||
--set JAVA_HOME ${openjdk17_headless}
|
||||
--prefix PATH : ${lib.makeBinPath [ openjdk21_headless ]} \
|
||||
--set JAVA_HOME ${openjdk21_headless}
|
||||
'');
|
||||
|
||||
# Execution in the macOS (10.13) sandbox fails with
|
||||
|
|
Loading…
Reference in a new issue