mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-22 14:45:27 +00:00
openrgb: Fix udev rules with hardcoded /bin/chmod
New rules introduced in openrgb 0.6. openrgb: Implement nixpkgs-review suggestions * warning: missing-phase-hooks * warning: unclear-gpl * warning: unnecessary-parallel-building
This commit is contained in:
parent
e4a0b10190
commit
25e46dda3d
|
@ -1,4 +1,4 @@
|
|||
{ lib, mkDerivation, fetchFromGitLab, qmake, libusb1, hidapi, pkg-config }:
|
||||
{ lib, mkDerivation, fetchFromGitLab, qmake, libusb1, hidapi, pkg-config, coreutils }:
|
||||
|
||||
mkDerivation rec {
|
||||
pname = "openrgb";
|
||||
|
@ -15,11 +15,18 @@ mkDerivation rec {
|
|||
buildInputs = [ libusb1 hidapi ];
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
mkdir -p $out/bin
|
||||
cp openrgb $out/bin
|
||||
|
||||
substituteInPlace 60-openrgb.rules \
|
||||
--replace /bin/chmod "${coreutils}/bin/chmod"
|
||||
|
||||
mkdir -p $out/etc/udev/rules.d
|
||||
cp 60-openrgb.rules $out/etc/udev/rules.d
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
doInstallCheck = true;
|
||||
|
@ -27,13 +34,11 @@ mkDerivation rec {
|
|||
HOME=$TMPDIR $out/bin/openrgb --help > /dev/null
|
||||
'';
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
meta = with lib; {
|
||||
description = "Open source RGB lighting control";
|
||||
homepage = "https://gitlab.com/CalcProgrammer1/OpenRGB";
|
||||
maintainers = with maintainers; [ jonringer ];
|
||||
license = licenses.gpl2;
|
||||
license = licenses.gpl2Plus;
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue