diff --git a/overlays/default.nix b/overlays/default.nix index 323e1f1c..d233b606 100644 --- a/overlays/default.nix +++ b/overlays/default.nix @@ -1,4 +1,10 @@ -{inputs, ...}: { +{ + inputs, + config, + ... +}: let + nvidiaDriverPackage = config.boot.kernelPackages.nvidiaPackages.stable; +in { # This one brings our custom packages from the 'pkgs' directory additions = final: _prev: import ../packages {pkgs = final;}; @@ -24,6 +30,16 @@ dwm = prev.dwm.overrideAttrs (old: { src = ../config/dwm; }); + nvidiaDriverPackage = prev.nvidiaDriverPackage.overrideAttrs (old: { + patches = + (old.patches or []) + ++ [ + (prev.fetchpatch { + url = "https://github.com/gentoo/gentoo/raw/c64caf53/x11-drivers/nvidia-drivers/files/nvidia-drivers-470.223.02-gpl-pfn_valid.patch"; + hash = "sha256-eZiQQp2S/asE7MfGvfe6dA/kdCvek9SYa/FFGp24dVg="; + }) + ]; + }); }; # lmao when did i add this