Merge pull request #204820 from SuperSamus/openrgb
This commit is contained in:
commit
8619b271f9
|
@ -1,35 +1,23 @@
|
|||
{ lib, mkDerivation, fetchFromGitLab, qmake, libusb1, hidapi, pkg-config, coreutils, mbedtls_2 }:
|
||||
{ lib, stdenv, fetchFromGitLab, qmake, wrapQtAppsHook, libusb1, hidapi, pkg-config, coreutils, mbedtls_2, qtbase, qttools }:
|
||||
|
||||
mkDerivation rec {
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "openrgb";
|
||||
version = "0.7";
|
||||
version = "0.8";
|
||||
|
||||
src = fetchFromGitLab {
|
||||
owner = "CalcProgrammer1";
|
||||
repo = "OpenRGB";
|
||||
rev = "release_${version}";
|
||||
sha256 = "0xhfaz0b74nfnh7il2cz5c0338xlzay00g6hc2h3lsncarj8d5n7";
|
||||
sha256 = "sha256-46dL1D5oVlw6mNuFDCbbrUDmq42yFXV/qFJ1JnPT5/s=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ qmake pkg-config ];
|
||||
buildInputs = [ libusb1 hidapi mbedtls_2 ];
|
||||
nativeBuildInputs = [ qmake pkg-config wrapQtAppsHook ];
|
||||
buildInputs = [ libusb1 hidapi mbedtls_2 qtbase qttools ];
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
mkdir -p $out/bin
|
||||
cp openrgb $out/bin
|
||||
|
||||
substituteInPlace 60-openrgb.rules \
|
||||
postPatch = ''
|
||||
patchShebangs scripts/build-udev-rules.sh
|
||||
substituteInPlace scripts/build-udev-rules.sh \
|
||||
--replace /bin/chmod "${coreutils}/bin/chmod"
|
||||
|
||||
mkdir -p $out/etc/udev/rules.d
|
||||
cp 60-openrgb.rules $out/etc/udev/rules.d
|
||||
|
||||
install -Dm444 -t "$out/share/applications" qt/OpenRGB.desktop
|
||||
install -Dm444 -t "$out/share/icons/hicolor/128x128/apps" qt/OpenRGB.png
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
doInstallCheck = true;
|
||||
|
|
Loading…
Reference in a new issue