1 { lib, stdenv, kernel, fetchFromGitHub }:
3 stdenv.mkDerivation rec {
7 src = fetchFromGitHub {
11 sha256 = "ZFwNdeJcSxzWtqjOF86SZpqhuz8jXZ2drvlQeIqsaNY=";
15 substituteInPlace Makefile --replace "modules_install" "INSTALL_MOD_PATH=$out modules_install"
16 sed -i '/depmod/d' Makefile
17 sed -i "10i\\\trmmod hid-logitech 2> /dev/null || true" Makefile
18 sed -i "11i\\\trmmod hid-logitech-new 2> /dev/null || true" Makefile
21 nativeBuildInputs = kernel.moduleBuildDependencies;
24 "KVERSION=${kernel.modDirVersion}"
25 "KDIR=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build"
29 description = "Experimental Logitech force feedback module for Linux";
30 homepage = "https://github.com/berarma/new-lg4ff";
31 license = licenses.gpl2Only;
32 maintainers = with maintainers; [ matthiasbenaets ];
33 platforms = platforms.linux;
34 broken = stdenv.hostPlatform.isAarch64;