summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorTodd Gamblin <tgamblin@llnl.gov>2017-03-07 09:32:43 -0800
committerTodd Gamblin <tgamblin@llnl.gov>2017-03-31 13:40:41 -0700
commit0331b08c64abbc3d7c185d9650007be1de238cfc (patch)
treeb24454c749587ffe7d4857554399c50f92def3f2 /bin
parentbc404532ea875ecc6982d049dc7c7f041aa74443 (diff)
downloadspack-0331b08c64abbc3d7c185d9650007be1de238cfc.tar.gz
spack-0331b08c64abbc3d7c185d9650007be1de238cfc.tar.bz2
spack-0331b08c64abbc3d7c185d9650007be1de238cfc.tar.xz
spack-0331b08c64abbc3d7c185d9650007be1de238cfc.zip
Update externals to work with Python 3
- Update YAML version to support Python 3 - Python 3 support for ordereddict backport - Exclude Python3 YAML from version tests. - Vendor six into Spack. - Make Python version-check tests work with Python 3 - Add ability to add version check exceptions with '# nopyqver' line comments.
Diffstat (limited to 'bin')
-rwxr-xr-xbin/spack7
1 files changed, 7 insertions, 0 deletions
diff --git a/bin/spack b/bin/spack
index f885f577c8..550b999eb9 100755
--- a/bin/spack
+++ b/bin/spack
@@ -46,6 +46,13 @@ sys.path.insert(0, SPACK_LIB_PATH)
SPACK_EXTERNAL_LIBS = os.path.join(SPACK_LIB_PATH, "external")
sys.path.insert(0, SPACK_EXTERNAL_LIBS)
+# Handle vendoring of YAML specially, as it has two versions.
+if sys.version_info[0] == 2:
+ SPACK_YAML_LIBS = os.path.join(SPACK_EXTERNAL_LIBS, "yaml/lib")
+else:
+ SPACK_YAML_LIBS = os.path.join(SPACK_EXTERNAL_LIBS, "yaml/lib3")
+sys.path.insert(0, SPACK_YAML_LIBS)
+
# Quick and dirty check to clean orphaned .pyc files left over from
# previous revisions. These files were present in earlier versions of
# Spack, were removed, but shadow system modules that Spack still