From c70f6b579b147775f58021dac5ad38d5bc474054 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Thu, 5 Apr 2018 22:09:27 +0200 Subject: =?UTF-8?q?=E2=80=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- custom/uucp-mediaserver/scripts.nix | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) (limited to 'custom') diff --git a/custom/uucp-mediaserver/scripts.nix b/custom/uucp-mediaserver/scripts.nix index 5020a60a..4acb8619 100644 --- a/custom/uucp-mediaserver/scripts.nix +++ b/custom/uucp-mediaserver/scripts.nix @@ -14,20 +14,24 @@ in stdenv.mkDerivation { name = "uucp-mediaserver"; src = ./scripts; - phases = [ "installPhase" ]; + phases = [ "buildPhase" "installPhase" ]; inherit (config) queueDir; + + buildPhase = '' + substituteAllInPlace $out/libexec/mediaspace + substituteAllInPlace $out/libexec/queue + substituteAllInPlace $out/libexec/queuespace + substituteAllInPlace $out/libexec/queuestatus + substituteAllInPlace $out/libexec/update-queuesize + ''; installPhase = '' - mkdir -p $out/libexec - - substituteFile $src/mediaspace $out/libexec/mediaspace - substituteFile $src/queue $out/libexec/queue - substituteFile $src/queuesize $out/libexec/queuesize - substituteFile $src/queuestatus $out/libexec/queuestatus - substituteFile $src/update-queuesize $out/libexec/update-queuesize + mkdir -p $out/libexec - mkdir -p $out/bin + install -m 755 -t $out/libexec mediaspace queue queuespace queuestatus update-queuesize + + mkdir -p $out/bin ${concatStringsSep "\n" (map mkSymlinks config.remoteNodes)} ''; -- cgit v1.2.3