flakes/packages/linux-lava/sources.nix

46 lines
1.2 KiB
Nix
Raw Normal View History

{ fetchFromGitHub, inputs, lib }:
let
2025-11-21 22:43:43 +11:00
version = "6.17.8";
2025-10-25 01:45:00 +00:00
kernelHash = "19spyyknps9dzb6mz5sk685a505hzqi144lqc0rdi6f9l5k72q4v";
2025-11-21 22:43:43 +11:00
kernelPatchHash = "0f1apr8wrsddik48mwsfq8d22x9019f1b023gvdzkpn2s58ja74n";
mm = lib.versions.majorMinor version;
hasPatch = (builtins.length (builtins.splitVersion version)) == 3;
tkgPatches = [
"0002-clear-patches"
"0003-glitched-base"
"0001-bore"
"0003-glitched-cfs"
"0012-misc-additions"
];
patch = path: {
name = "patch-${path}";
patch = path;
};
kernelPatchSrc = {
name = "patch";
patch = builtins.fetchurl {
url = "https://cdn.kernel.org/pub/linux/kernel/v${lib.versions.major version}.x/patch-${version}.xz";
sha256 = kernelPatchHash;
};
};
in {
inherit version;
2022-04-13 22:06:22 +07:00
src = builtins.fetchurl {
url = "https://cdn.kernel.org/pub/linux/kernel/v${lib.versions.major version}.x/linux-${mm}.tar.xz";
sha256 = kernelHash;
};
kernelPatches = lib.optionals hasPatch [
2024-06-11 19:44:49 +10:00
kernelPatchSrc
(patch ./bluetooth.patch)
2021-07-10 01:09:36 +07:00
]
++ builtins.map (name: {
inherit name;
patch = "${inputs.linux-tkg}/linux-tkg-patches/${mm}/${name}.patch";
}) tkgPatches
2024-06-11 19:44:49 +10:00
++ [ ];
}