2024-08-26 19:43:59 -04:00
|
|
|
{pkgs, config, ... }: {
|
2024-08-24 22:16:51 -04:00
|
|
|
# Enable video drivers
|
|
|
|
services.xserver.videoDrivers = ["nvidia"];
|
|
|
|
|
|
|
|
hardware.nvidia = {
|
|
|
|
modesetting.enable = true;
|
|
|
|
nvidiaSettings = false;
|
|
|
|
package = config.boot.kernelPackages.nvidiaPackages.beta;
|
2024-08-26 19:43:59 -04:00
|
|
|
open = false;
|
2024-08-24 22:16:51 -04:00
|
|
|
};
|
2024-08-26 15:40:42 -04:00
|
|
|
|
2024-08-26 19:43:59 -04:00
|
|
|
environment.sessionVariables = {
|
|
|
|
CUDA_PATH = "${pkgs.cudatoolkit}";
|
|
|
|
EXTRA_LDFLAGS = "-L/lib -L${pkgs.linuxPackages.nvidia_x11}/lib";
|
|
|
|
EXTRA_CCFLAGS = "-I/usr/include";
|
|
|
|
};
|
2024-08-24 22:16:51 -04:00
|
|
|
}
|