summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMario Melara <maamelara@gmail.com>2016-04-07 14:38:04 -0700
committerMario Melara <maamelara@gmail.com>2016-04-07 14:38:04 -0700
commit0ad317213c0f32c125c7043b5e57aa678ba63f8f (patch)
treea57287610b42ff51b4ecfb0b4dd322ceb34b8dbd
parent07df40320331c118306c40c36deae8d57ca6073c (diff)
downloadspack-0ad317213c0f32c125c7043b5e57aa678ba63f8f.tar.gz
spack-0ad317213c0f32c125c7043b5e57aa678ba63f8f.tar.bz2
spack-0ad317213c0f32c125c7043b5e57aa678ba63f8f.tar.xz
spack-0ad317213c0f32c125c7043b5e57aa678ba63f8f.zip
Changed architecture parser so that if user just enters in frontend or backend, then both the os and target will take those names. In the concretize method the frontend target/os and backend target/os will be picked to match each other
-rw-r--r--lib/spack/spack/spec.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/spack/spack/spec.py b/lib/spack/spack/spec.py
index fa2e9fd4c8..94d881da28 100644
--- a/lib/spack/spack/spec.py
+++ b/lib/spack/spack/spec.py
@@ -462,11 +462,10 @@ class Spec(object):
"""Called by the parser to set the architecture."""
if self.architecture: raise DuplicateArchitectureError(
"Spec for '%s' cannot have two architectures." % self.name)
- platform = spack.architecture.sys_type()
if '-' in architecture:
os, target = architecture.split('-')
- else:
- os = None
+ elif architecture == 'frontend' or architecture == 'backend':
+ os = architecture
target = architecture
self.architecture = spack.architecture.Arch(os, target)