From e1dc40b375847ce8ab352f95410258a4808825f0 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Sun, 7 Jun 2015 17:33:27 +0200 Subject: Hopefull try --- bragi.nix | 6 ++++-- customized/jack2.nix | 2 ++ customized/mpd.nix | 5 +++++ 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/bragi.nix b/bragi.nix index a1219f56..1282dfe9 100644 --- a/bragi.nix +++ b/bragi.nix @@ -68,6 +68,8 @@ serviceConfig = { Type = "simple"; ExecStart = "${pkgs.jack2}/bin/jackd -d alsa -M -H -r 96000"; + User = "mpd"; + Group = "audio"; }; }; @@ -82,8 +84,8 @@ } ''; }; - - users.extraUsers.guest = { + + users.extraUsers.gkleen = { name = "gkleen"; isNormalUser = true; uid = 1000; diff --git a/customized/jack2.nix b/customized/jack2.nix index 1432eea9..4788fb0a 100644 --- a/customized/jack2.nix +++ b/customized/jack2.nix @@ -33,6 +33,8 @@ stdenv.mkDerivation rec { installPhase = '' python waf install wrapProgram $out/bin/jack_control --set PYTHONPATH $PYTHONPATH + for bin in $out/bin/*; do + wrapProgram $bin --set JACK_PROMISCUOUS_SERVER 1 done ''; diff --git a/customized/mpd.nix b/customized/mpd.nix index 0b7b1edf..f579a4bf 100644 --- a/customized/mpd.nix +++ b/customized/mpd.nix @@ -100,6 +100,11 @@ in stdenv.mkDerivation rec { ++ opt stdenv.isLinux "--with-systemdsystemunitdir=$(out)/etc/systemd/system"; + postInstall = '' + wrapProgram $out/bin/mpd \ + --set JACK_PROMISCUOUS_SERVER 1 + ''; + NIX_LDFLAGS = '' ${if shoutSupport then "-lshout" else ""} ''; -- cgit v1.2.3