From 902fac185a22cab19a36a73916c93e9ad7f0dd1a Mon Sep 17 00:00:00 2001 From: Teodor Nikolov Date: Sun, 9 Aug 2020 20:44:05 +0200 Subject: blaspp: added explicit dependency on CUDA (#17965) --- var/spack/repos/builtin/packages/blaspp/package.py | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'var') diff --git a/var/spack/repos/builtin/packages/blaspp/package.py b/var/spack/repos/builtin/packages/blaspp/package.py index bcc5e80292..ddacfa22aa 100644 --- a/var/spack/repos/builtin/packages/blaspp/package.py +++ b/var/spack/repos/builtin/packages/blaspp/package.py @@ -6,7 +6,7 @@ from spack import * -class Blaspp(CMakePackage): +class Blaspp(CMakePackage, CudaPackage): """C++ API for the Basic Linear Algebra Subroutines. Developed by the Innovative Computing Laboratory at the University of Tennessee, Knoxville.""" @@ -62,6 +62,16 @@ class Blaspp(CMakePackage): else: args.append('-DBLAS_LIBRARY_THREADING="sequential"') + # `blaspp` has an implicit CUDA detection mechanism. This disables it + # in cases where it may backfire. One such case is when `cuda` is + # external and marked with `buildable=false`. `blaspp`'s CMake CUDA + # detection mechanism finds CUDA but doesn't set certain paths properly + # which leads to a build issues [1]. + # + # [1]: https://bitbucket.org/icl/blaspp/issues/6/compile-error-due-to-implicit-cuda + if '~cuda' in spec: + args.append('-DCMAKE_CUDA_COMPILER=') + # Missing: # # - acml : BLAS_LIBRARY="AMD ACML" -- cgit v1.2.3-60-g2f50