From 84dbf6948eed21e9cda8af92a4ca0d39b2ff7abc Mon Sep 17 00:00:00 2001 From: Glenn Johnson Date: Tue, 22 Sep 2020 11:35:13 -0500 Subject: [PATCH] Set conflicts parameter for cuda-11 (#18847) Magma is not currently compatible with CUDA-11. While this is reflected in the package, it is done with a comment in a `depends_on` directive, which has the effect of trying to install a version of CUDA that may be different from the one in the current environment, without any message to the end user. A `conflicts` is a better way to handle this. --- var/spack/repos/builtin/packages/magma/package.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/var/spack/repos/builtin/packages/magma/package.py b/var/spack/repos/builtin/packages/magma/package.py index ec2324290a5..c5442d774c3 100644 --- a/var/spack/repos/builtin/packages/magma/package.py +++ b/var/spack/repos/builtin/packages/magma/package.py @@ -36,14 +36,16 @@ class Magma(CMakePackage, CudaPackage): depends_on('blas') depends_on('lapack') depends_on('cuda@8:', when='@2.5.1:') # See PR #14471 - depends_on('cuda@:10.99999') # incompatible with CUDA 11 - # The previous line would ideally include "when='@:2.5.3'", but this - # doesn't work due to a problem with the concretizer. conflicts('~cuda', msg='Magma requires cuda') conflicts('cuda_arch=none', msg='Please indicate a CUDA arch value or values') + # currently not compatible with CUDA-11 + # https://bitbucket.org/icl/magma/issues/22/cuda-11-changes-issue + # https://bitbucket.org/icl/magma/issues/25/error-cusparsesolveanalysisinfo_t-does-not + conflicts('^cuda@11:', when='@:2.5.3') + patch('ibm-xl.patch', when='@2.2:2.5.0%xl') patch('ibm-xl.patch', when='@2.2:2.5.0%xl_r') patch('magma-2.3.0-gcc-4.8.patch', when='@2.3.0%gcc@:4.8')