mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-27 22:03:54 +03:00
libratbag: init at v0.9.903
Add package libratbag and service module ratbagd Libratbag contains ratbagd daemon and ratbagctl cli to configure buttons, dpi, leds, etc. of gaming mice. Add mvnetbiz to maintainers.
This commit is contained in:
parent
aba0fe5d62
commit
9a859fb7f9
@ -2808,6 +2808,11 @@
|
||||
github = "muflax";
|
||||
name = "Stefan Dorn";
|
||||
};
|
||||
mvnetbiz = {
|
||||
email = "mvnetbiz@gmail.com";
|
||||
github = "mvnetbiz";
|
||||
name = "Matt Votava";
|
||||
};
|
||||
myrl = {
|
||||
email = "myrl.0xf@gmail.com";
|
||||
github = "myrl";
|
||||
|
@ -275,6 +275,7 @@
|
||||
./services/hardware/nvidia-optimus.nix
|
||||
./services/hardware/pcscd.nix
|
||||
./services/hardware/pommed.nix
|
||||
./services/hardware/ratbagd.nix
|
||||
./services/hardware/sane.nix
|
||||
./services/hardware/sane_extra_backends/brscan4.nix
|
||||
./services/hardware/tcsd.nix
|
||||
|
32
nixos/modules/services/hardware/ratbagd.nix
Normal file
32
nixos/modules/services/hardware/ratbagd.nix
Normal file
@ -0,0 +1,32 @@
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
cfg = config.services.ratbagd;
|
||||
in
|
||||
{
|
||||
###### interface
|
||||
|
||||
options = {
|
||||
services.ratbagd = {
|
||||
enable = mkOption {
|
||||
default = false;
|
||||
description = ''
|
||||
Whether to enable ratbagd for configuring gaming mice.
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
###### implementation
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
# Give users access to the "ratbagctl" tool
|
||||
environment.systemPackages = [ pkgs.libratbag ];
|
||||
|
||||
services.dbus.packages = [ pkgs.libratbag ];
|
||||
|
||||
systemd.packages = [ pkgs.libratbag ];
|
||||
};
|
||||
}
|
36
pkgs/os-specific/linux/libratbag/default.nix
Normal file
36
pkgs/os-specific/linux/libratbag/default.nix
Normal file
@ -0,0 +1,36 @@
|
||||
{ stdenv, fetchFromGitHub, meson, ninja, pkgconfig
|
||||
, glib, systemd, udev, libevdev, gitMinimal, check, valgrind, swig, python3 }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "libratbag-${version}";
|
||||
version = "0.9.903";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "libratbag";
|
||||
repo = "libratbag";
|
||||
rev = "v${version}";
|
||||
sha256 = "0cr5skrb7a5mgj7dkm647ib8336hb88bf11blaf6xldafi8b0jlj";
|
||||
};
|
||||
|
||||
|
||||
# todo: python should be in buildInputs, but right now meson propagates
|
||||
# its own python. see: https://github.com/NixOS/nixpkgs/pull/46020
|
||||
nativeBuildInputs = [
|
||||
(python3.withPackages (ps: with ps; [ evdev pygobject3 ]))
|
||||
meson ninja pkgconfig gitMinimal swig check valgrind
|
||||
];
|
||||
|
||||
buildInputs = [ glib systemd udev libevdev ];
|
||||
|
||||
mesonFlags = [
|
||||
"-Dsystemd-unit-dir=./lib/systemd/system/"
|
||||
];
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "Configuration library for gaming mice";
|
||||
homepage = https://github.com/libratbag/libratbag;
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ mvnetbiz ];
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
@ -15022,6 +15022,8 @@ with pkgs;
|
||||
|
||||
libertinus = callPackage ../data/fonts/libertinus { };
|
||||
|
||||
libratbag = callPackage ../os-specific/linux/libratbag { };
|
||||
|
||||
libre-baskerville = callPackage ../data/fonts/libre-baskerville { };
|
||||
|
||||
libre-bodoni = callPackage ../data/fonts/libre-bodoni { };
|
||||
|
Loading…
Reference in New Issue
Block a user