From f670b4741560caaaf821f32cd4dc4a543855fe79 Mon Sep 17 00:00:00 2001 From: rewine Date: Tue, 4 Jun 2024 17:10:29 +0800 Subject: [PATCH] deepin-anything-module: init --- .../linux/deepin-anything-module/default.nix | 29 +++++++++++++++++++ pkgs/top-level/linux-kernels.nix | 2 ++ 2 files changed, 31 insertions(+) create mode 100644 pkgs/os-specific/linux/deepin-anything-module/default.nix diff --git a/pkgs/os-specific/linux/deepin-anything-module/default.nix b/pkgs/os-specific/linux/deepin-anything-module/default.nix new file mode 100644 index 000000000000..5ee7c8a35e81 --- /dev/null +++ b/pkgs/os-specific/linux/deepin-anything-module/default.nix @@ -0,0 +1,29 @@ +{ stdenv +, deepin +, kernel +}: + +stdenv.mkDerivation { + pname = "deepin-anything-module"; + inherit (deepin.deepin-anything) version src; + sourceRoot = "${deepin.deepin-anything.src.name}/src/kernelmod"; + + nativeBuildInputs = kernel.moduleBuildDependencies; + + buildPhase = '' + runHook preBuild + make kdir=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build + runHook postBuild + ''; + + installPhase = '' + runHook preInstall + install -D -t $out/lib/modules/${kernel.modDirVersion}/extra *.ko + runHook postInstall + ''; + + meta = deepin.deepin-anything.meta // { + description = "Deepin Anything file search tool (kernel modules)"; + }; +} + diff --git a/pkgs/top-level/linux-kernels.nix b/pkgs/top-level/linux-kernels.nix index bce80c21b32b..56a7a2c65d8c 100644 --- a/pkgs/top-level/linux-kernels.nix +++ b/pkgs/top-level/linux-kernels.nix @@ -336,6 +336,8 @@ in { cpupower = callPackage ../os-specific/linux/cpupower { }; + deepin-anything-module = callPackage ../os-specific/linux/deepin-anything-module { }; + ddcci-driver = callPackage ../os-specific/linux/ddcci { }; dddvb = callPackage ../os-specific/linux/dddvb { };