summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Kosukhin <sergey.kosukhin@mpimet.mpg.de>2021-04-14 23:49:48 +0200
committerGitHub <noreply@github.com>2021-04-14 14:49:48 -0700
commit05ebe52643b166c59cae099883f496b9b9dd2fb6 (patch)
treec8ff9f7b51749c3249925b89d08c905220e23c64
parent5309417f195d0b8e81bc5207caab8d366bb8841f (diff)
downloadspack-05ebe52643b166c59cae099883f496b9b9dd2fb6.tar.gz
spack-05ebe52643b166c59cae099883f496b9b9dd2fb6.tar.bz2
spack-05ebe52643b166c59cae099883f496b9b9dd2fb6.tar.xz
spack-05ebe52643b166c59cae099883f496b9b9dd2fb6.zip
claw package: support for cce11 (#22986)
-rw-r--r--var/spack/repos/builtin/packages/claw/package.py11
1 files changed, 8 insertions, 3 deletions
diff --git a/var/spack/repos/builtin/packages/claw/package.py b/var/spack/repos/builtin/packages/claw/package.py
index 380c53b9db..5356a89535 100644
--- a/var/spack/repos/builtin/packages/claw/package.py
+++ b/var/spack/repos/builtin/packages/claw/package.py
@@ -48,9 +48,14 @@ class Claw(CMakePackage):
filter_compiler_wrappers('claw_f.conf', relative_root='etc')
def flag_handler(self, name, flags):
- # https://gcc.gnu.org/gcc-10/porting_to.html
- if name == 'cflags' and self.spec.satisfies('%gcc@10:'):
- flags.append('-fcommon')
+ if name == 'cflags':
+ comp_spec = self.spec.compiler
+ # https://gcc.gnu.org/gcc-10/porting_to.html
+ # https://releases.llvm.org/11.0.0/tools/clang/docs/ReleaseNotes.html#modified-compiler-flags
+ # TODO: take care of other Clang-based compilers when they become
+ # real cases
+ if comp_spec.satisfies('gcc@10:') or comp_spec.satisfies('cce@11:'):
+ flags.append('-fcommon')
return flags, None, None