diff options
Diffstat (limited to 'pkgs/development/libraries/ctranslate2/default.nix')
-rw-r--r-- | pkgs/development/libraries/ctranslate2/default.nix | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/pkgs/development/libraries/ctranslate2/default.nix b/pkgs/development/libraries/ctranslate2/default.nix index 83eb9bf3a8953..58906b608231d 100644 --- a/pkgs/development/libraries/ctranslate2/default.nix +++ b/pkgs/development/libraries/ctranslate2/default.nix @@ -60,7 +60,7 @@ stdenv.mkDerivation rec { cudaPackages.cuda_cudart cudaPackages.libcublas cudaPackages.libcurand - ] ++ lib.optionals withCuDNN [ + ] ++ lib.optionals (withCUDA && withCuDNN) [ cudaPackages.cudnn ] ++ lib.optionals withOneDNN [ oneDNN @@ -87,5 +87,8 @@ stdenv.mkDerivation rec { changelog = "https://github.com/OpenNMT/CTranslate2/blob/${src.rev}/CHANGELOG.md"; license = licenses.mit; maintainers = with maintainers; [ hexa misuzu ]; + broken = + (lib.versionOlder cudaPackages.cudaVersion "11.4") + || !(withCuDNN -> withCUDA); }; } |