2023-07-15 17:15:38 +00:00
|
|
|
{ lib, python3Packages, fetchPypi }:
|
2020-12-25 13:55:36 +00:00
|
|
|
|
|
|
|
python3Packages.buildPythonApplication rec {
|
|
|
|
pname = "usbsdmux";
|
2024-02-07 01:22:34 +00:00
|
|
|
version = "24.1.1";
|
2020-12-25 13:55:36 +00:00
|
|
|
|
2023-07-15 17:15:38 +00:00
|
|
|
src = fetchPypi {
|
2020-12-25 13:55:36 +00:00
|
|
|
inherit pname version;
|
2024-07-27 06:49:29 +00:00
|
|
|
hash = "sha256-OtGgToDGUr6pBu9+LS/DxaYw/9+Pd6jPhxVDAM22HB4=";
|
2020-12-25 13:55:36 +00:00
|
|
|
};
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
# Remove the wrong GROUP=plugdev.
|
|
|
|
# The udev rule already has TAG+="uaccess", which is sufficient.
|
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace contrib/udev/99-usbsdmux.rules \
|
|
|
|
--replace-fail 'TAG+="uaccess", GROUP="plugdev"' 'TAG+="uaccess"'
|
|
|
|
'';
|
|
|
|
|
2021-04-12 18:23:04 +00:00
|
|
|
# usbsdmux is not meant to be used as an importable module and has no tests
|
|
|
|
doCheck = false;
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
postInstall = ''
|
|
|
|
install -Dm0444 -t $out/lib/udev/rules.d/ contrib/udev/99-usbsdmux.rules
|
|
|
|
'';
|
|
|
|
|
2020-12-25 13:55:36 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Control software for the LXA USB-SD-Mux";
|
|
|
|
homepage = "https://github.com/linux-automation/usbsdmux";
|
|
|
|
license = licenses.lgpl21;
|
|
|
|
maintainers = with maintainers; [ emantor ];
|
|
|
|
platforms = with platforms; linux;
|
|
|
|
};
|
|
|
|
}
|