Restore bootstrapping from binaries
Signed-off-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
This commit is contained in:
parent
543f830f57
commit
352442a383
@ -625,11 +625,13 @@ def tarball_directory_name(spec):
|
||||
Return name of the tarball directory according to the convention
|
||||
<os>-<architecture>/<compiler>/<package>-<version>/
|
||||
"""
|
||||
# FIXME (compiler as nodes): fix the naming scheme later to avoid using compiler
|
||||
return spec.format_path(
|
||||
f"{spec.architecture}/{spec.compiler_annotation.name}-{spec.compiler_annotation.version}/"
|
||||
f"{spec.name}-{spec.version}"
|
||||
)
|
||||
if not spec.compiler_as_nodes():
|
||||
return spec.format_path(
|
||||
f"{spec.architecture}/{spec.compiler_annotation.name}"
|
||||
f"-{spec.compiler_annotation.version}/{spec.name}-{spec.version}"
|
||||
)
|
||||
|
||||
return spec.format_path(f"{spec.architecture.platform}/{spec.name}-{spec.version}")
|
||||
|
||||
|
||||
def tarball_name(spec, ext):
|
||||
@ -637,12 +639,16 @@ def tarball_name(spec, ext):
|
||||
Return the name of the tarfile according to the convention
|
||||
<os>-<architecture>-<package>-<dag_hash><ext>
|
||||
"""
|
||||
# FIXME (compiler as nodes): fix the naming scheme later to avoid using compiler
|
||||
spec_formatted = (
|
||||
f"{spec.architecture}-{spec.compiler_annotation.name}"
|
||||
f"-{spec.compiler_annotation.version}-{spec.name}"
|
||||
f"-{spec.version}-{spec.dag_hash()}"
|
||||
)
|
||||
if not spec.compiler_as_nodes():
|
||||
spec_formatted = (
|
||||
f"{spec.architecture}-{spec.compiler_annotation.name}"
|
||||
f"-{spec.compiler_annotation.version}-{spec.name}"
|
||||
f"-{spec.version}-{spec.dag_hash()}"
|
||||
)
|
||||
else:
|
||||
spec_formatted = (
|
||||
f"{spec.architecture.platform}-{spec.name}-{spec.version}-{spec.dag_hash()}"
|
||||
)
|
||||
return f"{spec_formatted}{ext}"
|
||||
|
||||
|
||||
|
@ -4493,6 +4493,10 @@ def attach_git_version_lookup(self):
|
||||
if isinstance(v, vn.GitVersion) and v._ref_version is None:
|
||||
v.attach_lookup(spack.version.git_ref_lookup.GitRefLookup(self.fullname))
|
||||
|
||||
def compiler_as_nodes(self) -> bool:
|
||||
"""Returns True if compiler are treated as nodes"""
|
||||
return not hasattr(self, "compiler_annotation")
|
||||
|
||||
|
||||
class VariantMap(lang.HashableMap):
|
||||
"""Map containing variant instances. New values can be added only
|
||||
|
Loading…
Reference in New Issue
Block a user