solaar: 1.0.2 -> 1.0.5

This commit is contained in:
Peter Hoeg 2021-05-10 16:07:45 +08:00
parent 4a9b0f0eb4
commit 6e7fac368f

View file

@ -1,46 +1,59 @@
{ fetchFromGitHub, lib, gobject-introspection, gtk3, python3Packages }:
# Although we copy in the udev rules here, you probably just want to use logitech-udev-rules instead of
# adding this to services.udev.packages on NixOS
# Although we copy in the udev rules here, you probably just want to use
# logitech-udev-rules instead of adding this to services.udev.packages on NixOS
python3Packages.buildPythonApplication rec {
pname = "solaar";
version = "1.0.2";
version = "1.0.5";
src = fetchFromGitHub {
owner = "pwr-Solaar";
repo = "Solaar";
rev = version;
sha256 = "0k5z9dap6rawiafkg1x7zjx51ala7wra6j6lvc2nn0y8r79yp7a9";
sha256 = "sha256-k87DqIkvy5CVEsHT82ZArSM2JBi5sYdSCPfP4KjI850=";
};
propagatedBuildInputs = with python3Packages; [ gobject-introspection gtk3 pygobject3 pyudev ];
propagatedBuildInputs = with python3Packages; [
gobject-introspection
gtk3
psutil
pygobject3
pyudev
pyyaml
xlib
];
makeWrapperArgs = [
"--prefix PYTHONPATH : $PYTHONPATH"
"--prefix GI_TYPELIB_PATH : $GI_TYPELIB_PATH"
];
# the -cli symlink is just to maintain compabilility with older versions where
# there was a difference between the GUI and CLI versions.
postInstall = ''
wrapProgram "$out/bin/solaar" \
--prefix PYTHONPATH : "$PYTHONPATH" \
--prefix GI_TYPELIB_PATH : "$GI_TYPELIB_PATH"
wrapProgram "$out/bin/solaar-cli" \
--prefix PYTHONPATH : "$PYTHONPATH" \
--prefix GI_TYPELIB_PATH : "$GI_TYPELIB_PATH"
ln -s $out/bin/solaar $out/bin/solaar-cli
install -Dm644 -t $out/etc/udev/rules.d rules.d/*.rules
install -Dm444 -t $out/etc/udev/rules.d rules.d/*.rules
'';
enableParallelBuilding = true;
# No tests
doCheck = false;
meta = with lib; {
description = "Linux devices manager for the Logitech Unifying Receiver";
longDescription = ''
Solaar is a Linux device manager for Logitechs Unifying Receiver
peripherals. It is able to pair/unpair devices to the receiver, and for
most devices read battery status.
Solaar is a Linux manager for many Logitech keyboards, mice, and trackpads that
connect wirelessly to a USB Unifying, Lightspeed, or Nano receiver, connect
directly via a USB cable, or connect via Bluetooth. Solaar does not work with
peripherals from other companies.
It comes in two flavors, command-line and GUI. Both are able to list the
devices paired to a Unifying Receiver, show detailed info for each
device, and also pair/unpair supported devices with the receiver.
Solaar can be used as a GUI application or via its command-line interface.
To be able to use it, make sure you have access to /dev/hidraw* files.
This tool requires either to be run with root/sudo or alternatively to have the udev rules files installed. On NixOS this can be achieved by setting `hardware.logitech.wireless.enable`.
'';
license = licenses.gpl2;
homepage = "https://pwr-solaar.github.io/Solaar/";
platforms = platforms.linux;
license = licenses.gpl2Only;
maintainers = with maintainers; [ spinus ysndr ];
platforms = platforms.linux;
};
}