From 6121046a1c5dbea7703521f9dc816abf47eab943 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Tue, 21 Aug 2012 08:33:10 -0400 Subject: [PATCH] systemd: Set the path to pkttyagent This allows commands like "systemctl reboot" to ask for authentication when run by mere mortals. --- pkgs/os-specific/linux/systemd/default.nix | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/pkgs/os-specific/linux/systemd/default.nix b/pkgs/os-specific/linux/systemd/default.nix index 4cda7191e4a2..e6e5822c9eac 100644 --- a/pkgs/os-specific/linux/systemd/default.nix +++ b/pkgs/os-specific/linux/systemd/default.nix @@ -49,7 +49,14 @@ stdenv.mkDerivation rec { done ''; - NIX_CFLAGS_COMPILE = "-DKBD_LOADKEYS=\"${kbd}/bin/loadkeys\" -DKBD_SETFONT=\"${kbd}/bin/setfont\" -fno-stack-protector"; + NIX_CFLAGS_COMPILE = + [ "-DKBD_LOADKEYS=\"${kbd}/bin/loadkeys\"" + "-DKBD_SETFONT=\"${kbd}/bin/setfont\"" + # Can't say ${polkit}/bin/pkttyagent here because that would + # lead to a cyclic dependency. + "-DPOLKIT_AGENT_BINARY_PATH=\"/run/current-system/sw/bin/pkttyagent\"" + "-fno-stack-protector" + ]; makeFlags = "CPPFLAGS=-I${stdenv.gcc.libc}/include";