summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
authorSimon Frasch <simon.frasch@cscs.ch>2022-02-11 22:17:40 +0100
committerGitHub <noreply@github.com>2022-02-11 14:17:40 -0700
commitdc949a5bdafc07523ec86815a133e720fc24d09e (patch)
tree1d3e6c5ba62dc49f48b5ab5c56fedcca21162e78 /var
parent7ec9958b485390825fc2756d88dab7cf77b17314 (diff)
downloadspack-dc949a5bdafc07523ec86815a133e720fc24d09e.tar.gz
spack-dc949a5bdafc07523ec86815a133e720fc24d09e.tar.bz2
spack-dc949a5bdafc07523ec86815a133e720fc24d09e.tar.xz
spack-dc949a5bdafc07523ec86815a133e720fc24d09e.zip
spfft: fix missing hipFFT dependency with latest ROCm versions (#28880)
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/spfft/package.py27
1 files changed, 15 insertions, 12 deletions
diff --git a/var/spack/repos/builtin/packages/spfft/package.py b/var/spack/repos/builtin/packages/spfft/package.py
index 5c781765e7..e6385b27fd 100644
--- a/var/spack/repos/builtin/packages/spfft/package.py
+++ b/var/spack/repos/builtin/packages/spfft/package.py
@@ -47,20 +47,23 @@ class Spfft(CMakePackage, CudaPackage):
# ROCM variants + dependencies
variant('rocm', default=False, description="Use ROCm backend")
- amdgpu_targets = (
- 'gfx701', 'gfx801', 'gfx802', 'gfx803',
- 'gfx900', 'gfx906', 'gfx908', 'gfx1010',
- 'gfx1011', 'gfx1012'
- )
-
- depends_on('rocfft', when='+rocm')
- depends_on('hip', when='+rocm')
- variant('amdgpu_target', default='gfx803,gfx900,gfx906', multi=True, values=amdgpu_targets, when='+rocm')
-
depends_on('cuda@:10', when='@:0.9.11 +cuda')
- # FindHIP cmake script only works for < 4.1
- depends_on('hip@:4.0', when='@:1.0.1 +rocm')
+ with when('+rocm'):
+ # FindHIP cmake script only works for < 4.1
+ depends_on('hip@:4.0', when='@:1.0.1')
+ depends_on('hip')
+ depends_on('rocfft')
+ # rocFFT and hipFFT have split with latest versions
+ depends_on('hipfft', when='^rocfft@4.1.0:')
+
+ amdgpu_targets = (
+ 'gfx701', 'gfx801', 'gfx802', 'gfx803',
+ 'gfx900', 'gfx906', 'gfx908', 'gfx1010',
+ 'gfx1011', 'gfx1012'
+ )
+ variant('amdgpu_target', default='gfx803,gfx900,gfx906', multi=True,
+ values=amdgpu_targets)
# Fix compilation error in some cases due to missing include statement
# before version 1.0.3