mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-22 13:43:22 +00:00
1d63f89caa
There are many different versions of the `cudatoolkit` and related cuda packages, and it can be tricky to ensure they remain compatible. - `cudaPackages` is now a package set with `cudatoolkit`, `cudnn`, `cutensor`, `nccl`, as well as `cudatoolkit` split into smaller packages ("redist"); - expressions should now use `cudaPackages` as parameter instead of the individual cuda packages; - `makeScope` is now used, so it is possible to use `.overrideScope'` to set e.g. a different `cudnn` version; - `release-cuda.nix` is introduced to easily evaluate cuda packages using hydra.
16 lines
515 B
Nix
16 lines
515 B
Nix
final: prev: let
|
|
### Cuda Toolkit
|
|
|
|
# Function to build the class cudatoolkit package
|
|
buildCudaToolkitPackage = final.callPackage ./common.nix;
|
|
|
|
# Version info for the classic cudatoolkit packages that contain everything that is in redist.
|
|
cudatoolkitVersions = final.lib.importTOML ./versions.toml;
|
|
|
|
### Add classic cudatoolkit package
|
|
cudatoolkit = buildCudaToolkitPackage ((attrs: attrs // { gcc = prev.pkgs.${attrs.gcc}; }) cudatoolkitVersions.${final.cudaVersion});
|
|
|
|
in {
|
|
inherit cudatoolkit;
|
|
}
|