autorandr: put xrandr into PATH

This commit is contained in:
Joerg Thalheim 2017-10-09 23:46:40 +01:00
parent a61304e3cb
commit 3541b9a72e

View File

@ -1,7 +1,9 @@
{ stdenv
, python3Packages
, fetchFromGitHub
, systemd }:
, systemd
, xrandr
, makeWrapper }:
let
python = python3Packages.python;
@ -12,6 +14,7 @@ in
name = "autorandr-${version}";
buildInputs = [ python ];
nativeBuildInputs = [ makeWrapper ];
installPhase = ''
runHook preInstall
@ -33,9 +36,15 @@ in
make install TARGETS='udev' PREFIX=$out DESTDIR=$out \
UDEV_RULES_DIR=/etc/udev/rules.d
''}
runHook postInstall
'';
postFixup = ''
wrapProgram $out/bin/autorandr \
--prefix PATH : ${xrandr}/bin
'';
src = fetchFromGitHub {
owner = "phillipberndt";
repo = "autorandr";