mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-23 22:23:15 +00:00
45e6c607d6
nvidia_x11_open: unbreak 5.19 common kernel code is shared, if the closed build is broken, so is the open one. nvidia_x11_production: add alias, sort names nvidia_x11: reintroduce stable as a pure alias nvidia_x11: don't use alias in override
41 lines
996 B
Nix
41 lines
996 B
Nix
{ stdenv
|
|
, lib
|
|
, fetchFromGitHub
|
|
, kernel
|
|
, nvidia_x11
|
|
, hash
|
|
, broken ? false
|
|
}:
|
|
|
|
stdenv.mkDerivation {
|
|
pname = "nvidia-open";
|
|
version = "${kernel.version}-${nvidia_x11.version}";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "NVIDIA";
|
|
repo = "open-gpu-kernel-modules";
|
|
rev = nvidia_x11.version;
|
|
inherit hash;
|
|
};
|
|
|
|
nativeBuildInputs = kernel.moduleBuildDependencies;
|
|
|
|
makeFlags = kernel.makeFlags ++ [
|
|
"SYSSRC=${kernel.dev}/lib/modules/${kernel.modDirVersion}/source"
|
|
"SYSOUT=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build"
|
|
"MODLIB=$(out)/lib/modules/${kernel.modDirVersion}"
|
|
];
|
|
|
|
installTargets = [ "modules_install" ];
|
|
enableParallelBuilding = true;
|
|
|
|
meta = with lib; {
|
|
description = "NVIDIA Linux Open GPU Kernel Module";
|
|
homepage = "https://github.com/NVIDIA/open-gpu-kernel-modules";
|
|
license = with licenses; [ gpl2Plus mit ];
|
|
platforms = platforms.linux;
|
|
maintainers = with maintainers; [ nickcao ];
|
|
inherit broken;
|
|
};
|
|
}
|