Add sensei-raw-ctl

The GUI might not work, as it might require some kind of integration
with polkit.
This commit is contained in:
Přemysl Eric Janouch 2023-06-30 02:36:21 +02:00
parent 76727f875f
commit b825086d3d
Signed by: p
GPG Key ID: A0420B94F92B9493
1 changed files with 57 additions and 0 deletions

57
sensei-raw-ctl-master.nix Normal file
View File

@ -0,0 +1,57 @@
{ pkgs ? import <nixpkgs> { }
, local ? false
, full ? true
}:
pkgs.stdenv.mkDerivation rec {
pname = "sensei-raw-ctl";
version = "master";
nativeBuildInputs = with pkgs; [
cmake
pkg-config
help2man
];
buildInputs = with pkgs; [
libusb
] ++ lib.optionals full [
gtk3
# To address pkg-config warnings, all the way down.
libthai
pcre2
libdatrie
libepoxy
] ++ lib.optionals (full && !stdenv.isDarwin) [
libxkbcommon
xorg.libXdmcp
xorg.libXtst
] ++ lib.optionals (full && stdenv.isLinux) [
util-linux
libselinux
libsepol
pcre
];
src = if local then
builtins.path {
path = ../${pname}/git;
name = "${pname}";
}
else
fetchGit {
url = "https://git.janouch.name/p/${pname}.git";
submodules = true;
ref = "master";
};
doCheck = true;
meta = with pkgs.lib; {
description = "SteelSeries Sensei Raw control utility";
homepage = "https://git.janouch.name/p/${pname}";
platforms = platforms.all;
license = licenses.bsd0;
};
}