Use jdk11 in nix packages

This commit is contained in:
Eike Kettner 2021-01-12 01:09:15 +01:00
parent f18b763dee
commit b57ceb6764

View File

@ -1,4 +1,4 @@
cfg: {stdenv, fetchzip, file, curl, inotifyTools, fetchurl, jre8, bash}: cfg: {stdenv, fetchzip, file, curl, inotifyTools, fetchurl, jdk11, bash}:
let let
meta = with stdenv.lib; { meta = with stdenv.lib; {
description = "Docspell helps to organize and archive your paper documents."; description = "Docspell helps to organize and archive your paper documents.";
@ -12,7 +12,7 @@ in
src = fetchzip cfg.server; src = fetchzip cfg.server;
buildInputs = [ jre8 ]; buildInputs = [ jdk11 ];
buildPhase = "true"; buildPhase = "true";
@ -21,7 +21,7 @@ in
cp -R * $out/docspell-restserver-${cfg.version}/ cp -R * $out/docspell-restserver-${cfg.version}/
cat > $out/bin/docspell-restserver <<-EOF cat > $out/bin/docspell-restserver <<-EOF
#!${bash}/bin/bash #!${bash}/bin/bash
$out/docspell-restserver-${cfg.version}/bin/docspell-restserver -java-home ${jre8} "\$@" $out/docspell-restserver-${cfg.version}/bin/docspell-restserver -java-home ${jdk11} "\$@"
EOF EOF
chmod 755 $out/bin/docspell-restserver chmod 755 $out/bin/docspell-restserver
''; '';
@ -34,7 +34,7 @@ in
src = fetchzip cfg.joex; src = fetchzip cfg.joex;
buildInputs = [ jre8 ]; buildInputs = [ jdk11 ];
buildPhase = "true"; buildPhase = "true";
@ -43,7 +43,7 @@ in
cp -R * $out/docspell-joex-${cfg.version}/ cp -R * $out/docspell-joex-${cfg.version}/
cat > $out/bin/docspell-joex <<-EOF cat > $out/bin/docspell-joex <<-EOF
#!${bash}/bin/bash #!${bash}/bin/bash
$out/docspell-joex-${cfg.version}/bin/docspell-joex -java-home ${jre8} "\$@" $out/docspell-joex-${cfg.version}/bin/docspell-joex -java-home ${jdk11} "\$@"
EOF EOF
chmod 755 $out/bin/docspell-joex chmod 755 $out/bin/docspell-joex
''; '';