2021-01-11 10:54:33 +03:00
|
|
|
{ lib, stdenv, fetchgit, python3, coreutils }:
|
2019-02-22 22:45:16 +03:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "acpilight";
|
2019-06-25 01:20:26 +03:00
|
|
|
version = "1.2";
|
2019-02-22 22:45:16 +03:00
|
|
|
|
|
|
|
src = fetchgit {
|
|
|
|
url = "https://gitlab.com/wavexx/acpilight.git";
|
|
|
|
rev = "v${version}";
|
2019-06-25 01:20:26 +03:00
|
|
|
sha256 = "1r0r3nx6x6vkpal6vci0zaa1n9dfacypldf6k8fxg7919vzxdn1w";
|
2019-02-22 22:45:16 +03:00
|
|
|
};
|
|
|
|
|
2019-04-01 17:19:13 +03:00
|
|
|
pyenv = python3.withPackages (pythonPackages: with pythonPackages; [
|
2021-07-21 00:26:16 +03:00
|
|
|
configargparse
|
2019-02-22 22:45:16 +03:00
|
|
|
]);
|
|
|
|
|
|
|
|
postConfigure = ''
|
|
|
|
substituteInPlace 90-backlight.rules --replace /bin ${coreutils}/bin
|
2019-06-22 23:10:32 +03:00
|
|
|
substituteInPlace Makefile --replace udevadm true
|
2019-02-22 22:45:16 +03:00
|
|
|
'';
|
|
|
|
|
2019-06-22 23:10:32 +03:00
|
|
|
buildInputs = [ pyenv ];
|
2019-02-22 22:45:16 +03:00
|
|
|
|
|
|
|
makeFlags = [ "DESTDIR=$(out) prefix=" ];
|
|
|
|
|
2021-01-11 10:54:33 +03:00
|
|
|
meta = with lib; {
|
2019-02-22 22:45:16 +03:00
|
|
|
homepage = "https://gitlab.com/wavexx/acpilight";
|
|
|
|
description = "ACPI backlight control";
|
|
|
|
license = licenses.gpl3;
|
2019-08-18 22:16:19 +03:00
|
|
|
maintainers = with maintainers; [ smakarov ];
|
2019-02-22 22:45:16 +03:00
|
|
|
platforms = platforms.linux;
|
2022-04-20 01:50:21 +03:00
|
|
|
mainProgram = "xbacklight";
|
2019-02-22 22:45:16 +03:00
|
|
|
};
|
|
|
|
}
|