We've seen this in easybuilders/easybuild-easyconfigs#13746
The build failure for non-CUDA versions was
Can't build Clang with CUDA support without specifying 'cuda-compute-capabilities' (at easybuild/easybuild-easyblocks/easybuild/easyblocks/c/clang.py:327 in configure_step)
but that should only be a possible error if we're doing a CUDA build.
The issue is that we're modifying the lists in DEFAULT_TARGETS_MAP:
>>> DEFAULT_TARGETS_MAP = { 'POWER': ['PowerPC'], 'X86_64': ['X86'] }
>>> a = DEFAULT_TARGETS_MAP.get('X86_64', None)
>>> a += ['NVPTX']
>>> DEFAULT_TARGETS_MAP
{'POWER': ['PowerPC'], 'X86_64': ['X86', 'NVPTX']}
We have similar lookups in llvm.py but there we do not add to the list, so (currently) there is no issue.
In lammps.py the items are strings, which are immutable.