summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
authorThomas Gruber <Thomas.Roehl@googlemail.com>2020-03-12 14:44:43 +0100
committerGitHub <noreply@github.com>2020-03-12 14:44:43 +0100
commite916a9424ca6195e0685071f3bf3a8f532cb22fe (patch)
treee2223e8da3484d06d9e81cbab25ea722a5fb1478 /var
parentad1a28ee48a46ef8400b43f3f21c33ec8c5f2311 (diff)
downloadspack-e916a9424ca6195e0685071f3bf3a8f532cb22fe.tar.gz
spack-e916a9424ca6195e0685071f3bf3a8f532cb22fe.tar.bz2
spack-e916a9424ca6195e0685071f3bf3a8f532cb22fe.tar.xz
spack-e916a9424ca6195e0685071f3bf3a8f532cb22fe.zip
likwid: add compiler selection for ARM and POWER architecture (#14183)
Co-Authored-By: Massimiliano Culpo <massimiliano.culpo@gmail.com>
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/likwid/package.py11
1 files changed, 7 insertions, 4 deletions
diff --git a/var/spack/repos/builtin/packages/likwid/package.py b/var/spack/repos/builtin/packages/likwid/package.py
index c121b1ef35..8556fb0d8e 100644
--- a/var/spack/repos/builtin/packages/likwid/package.py
+++ b/var/spack/repos/builtin/packages/likwid/package.py
@@ -42,8 +42,6 @@ class Likwid(Package):
depends_on('perl', type=('build', 'run'))
- supported_compilers = {'clang': 'CLANG', 'gcc': 'GCC', 'intel': 'ICC'}
-
def patch(self):
files = glob.glob('perl/*.*') + glob.glob('bench/perl/*.*')
@@ -61,13 +59,18 @@ class Likwid(Package):
*files)
def install(self, spec, prefix):
- if self.compiler.name not in self.supported_compilers:
+ supported_compilers = {'clang': 'CLANG', 'gcc': 'GCC', 'intel': 'ICC'}
+ if spec.target.family == 'aarch64':
+ supported_compilers = {'gcc': 'GCCARMv8', 'clang': 'ARMCLANG'}
+ elif spec.target.family == 'ppc64' or spec.target.family == 'ppc64le':
+ supported_compilers = {'gcc': 'GCCPOWER'}
+ if self.compiler.name not in supported_compilers:
raise RuntimeError('{0} is not a supported compiler \
to compile Likwid'.format(self.compiler.name))
filter_file('^COMPILER .*',
'COMPILER = ' +
- self.supported_compilers[self.compiler.name],
+ supported_compilers[self.compiler.name],
'config.mk')
filter_file('^PREFIX .*',
'PREFIX = ' +