diff options
author | Greg Becker <becker33@llnl.gov> | 2020-06-25 12:13:26 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-06-25 19:13:26 +0200 |
commit | f936e3a1dbc43629e01a3a7e2cc1682419cb381b (patch) | |
tree | 5fca95fc68507c3fb5f6639bdafe4a5a81058e11 /lib/spack/docs/environments.rst | |
parent | e04c89f0867ba275bf7926a42f175f09ac6cd9dc (diff) | |
download | spack-f936e3a1dbc43629e01a3a7e2cc1682419cb381b.tar.gz spack-f936e3a1dbc43629e01a3a7e2cc1682419cb381b.tar.bz2 spack-f936e3a1dbc43629e01a3a7e2cc1682419cb381b.tar.xz spack-f936e3a1dbc43629e01a3a7e2cc1682419cb381b.zip |
environment spec lists: improve ability to query architecture in when clauses (#17056)
Diffstat (limited to 'lib/spack/docs/environments.rst')
-rw-r--r-- | lib/spack/docs/environments.rst | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/lib/spack/docs/environments.rst b/lib/spack/docs/environments.rst index b80e36b4b2..cec7224a86 100644 --- a/lib/spack/docs/environments.rst +++ b/lib/spack/docs/environments.rst @@ -647,7 +647,7 @@ named list ``compilers`` is ``['%gcc', '%clang', '%intel']`` on spack: definitions: - compilers: ['%gcc', '%clang'] - - when: target == 'x86_64' + - when: arch.satisfies('x86_64:') compilers: ['%intel'] .. note:: @@ -666,8 +666,12 @@ The valid variables for a ``when`` clause are: #. ``target``. The target string of the default Spack architecture on the system. -#. ``architecture`` or ``arch``. The full string of the - default Spack architecture on the system. +#. ``architecture`` or ``arch``. A Spack spec satisfying the default Spack + architecture on the system. This supports querying via the ``satisfies`` + method, as shown above. + +#. ``arch_str``. The architecture string of the default Spack architecture + on the system. #. ``re``. The standard regex module in Python. |