microsoft/surface: flatten 'repos' object

This commit is contained in:
Andre 2025-11-24 17:47:45 -05:00
parent abb5f782d3
commit ae4fcae923
2 changed files with 8 additions and 15 deletions

View file

@ -33,27 +33,22 @@ let
abort "Invalid kernel version: ${kernelVersion}"; abort "Invalid kernel version: ${kernelVersion}";
# Fetch the latest linux-surface patches # Fetch the latest linux-surface patches
repos = pkgs.callPackage ( linux-surface = pkgs.fetchFromGitHub {
{ fetchFromGitHub }: owner = "linux-surface";
{ repo = "linux-surface";
linux-surface = fetchFromGitHub { rev = "50d0ed6be462a5fdb643cfe8469bf69158afae42";
owner = "linux-surface"; hash = "sha256-ozvYrZDiVtMkdCcVnNEdlF2Kdw4jivW0aMJrDynN3Hk=";
repo = "linux-surface"; };
rev = "50d0ed6be462a5fdb643cfe8469bf69158afae42";
hash = "sha256-ozvYrZDiVtMkdCcVnNEdlF2Kdw4jivW0aMJrDynN3Hk=";
};
}
) { };
# Fetch and build the kernel # Fetch and build the kernel
inherit (pkgs.callPackage ./kernel/linux-package.nix { inherit repos; }) inherit (pkgs.callPackage ./kernel/linux-package.nix { })
linuxPackage linuxPackage
surfacePatches surfacePatches
; ;
kernelPatches = surfacePatches { kernelPatches = surfacePatches {
version = srcVersion; version = srcVersion;
patchFn = ./kernel/${versions.majorMinor srcVersion}/patches.nix; patchFn = ./kernel/${versions.majorMinor srcVersion}/patches.nix;
patchSrc = (repos.linux-surface + "/patches/${versions.majorMinor srcVersion}"); patchSrc = (linux-surface + "/patches/${versions.majorMinor srcVersion}");
}; };
kernelPackages = linuxPackage { kernelPackages = linuxPackage {
inherit kernelPatches; inherit kernelPatches;

View file

@ -4,7 +4,6 @@
fetchurl, fetchurl,
buildLinux, buildLinux,
linuxPackagesFor, linuxPackagesFor,
repos,
}: }:
let let
@ -74,7 +73,6 @@ in
{ {
inherit inherit
linuxPackage linuxPackage
repos
surfacePatches surfacePatches
versionsOf versionsOf
isVersionOf isVersionOf