Skip to content

Commit

Permalink
Merge pull request #279660 from markuskowa/fix-spfft-sirius
Browse files Browse the repository at this point in the history
spfft,sirius: fix CUDA build
  • Loading branch information
markuskowa authored Jan 9, 2024
2 parents 94e7fbc + 8156485 commit 1e4909f
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 7 deletions.
10 changes: 7 additions & 3 deletions pkgs/by-name/si/sirius/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ stdenv.mkDerivation rec {
cmake
gfortran
pkg-config
];
] ++ lib.optional (gpuBackend == "cuda") cudaPackages.cuda_nvcc;

buildInputs = [
blas
Expand All @@ -72,8 +72,12 @@ stdenv.mkDerivation rec {
eigen
libvdwxc
]
++ lib.optional (gpuBackend == "cuda") cudaPackages.cudatoolkit
++ lib.optionals (gpuBackend == "rocm") [
++ lib.optionals (gpuBackend == "cuda") [
cudaPackages.cuda_cudart
cudaPackages.cuda_profiler_api
cudaPackages.cudatoolkit
cudaPackages.libcublas
] ++ lib.optionals (gpuBackend == "rocm") [
rocmPackages.clr
rocmPackages.rocblas
] ++ lib.optional stdenv.isDarwin llvmPackages.openmp
Expand Down
9 changes: 5 additions & 4 deletions pkgs/by-name/sp/spfft/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -34,13 +34,14 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [
cmake
gfortran
];
] ++ lib.optional (gpuBackend == "cuda") cudaPackages.cuda_nvcc;

buildInputs = [
fftw
]
++ lib.optional (gpuBackend == "cuda") cudaPackages.cudatoolkit
++ lib.optionals (gpuBackend == "rocm") [
] ++ lib.optionals (gpuBackend == "cuda") [
cudaPackages.libcufft
cudaPackages.cuda_cudart
] ++ lib.optionals (gpuBackend == "rocm") [
rocmPackages.clr
rocmPackages.rocfft
rocmPackages.hipfft
Expand Down

0 comments on commit 1e4909f

Please sign in to comment.