From df65297502e407e8e41bae8ea006d0c3bbf02b7c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lorenz=20H=C3=BCdepohl?= <dev@stellardeath.org> Date: Tue, 26 Oct 2021 17:48:55 +0200 Subject: [PATCH] New location for mofed stack --- mpcdf_common.py | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/mpcdf_common.py b/mpcdf_common.py index 7a7430e..6ab446d 100644 --- a/mpcdf_common.py +++ b/mpcdf_common.py @@ -610,6 +610,15 @@ def parse_prjconf(api_url, project): return orig_prjconf, prjconf_head, prjconf_ours, prjconf_tail +def openmpi_flavor_dependencies(flavor, distribution): + if flavor.startswith("mofed_"): + mofed_version = flavor[len("mofed_"):].replace("_", ".") + mofed_repo = "extern:mofed:" + mofed_version + return ((mofed_repo, distribution),) + else: + return () + + def mpcdf_setup_subproject(api_url, project, distribution, microarchitecture, parent=None, dry_run=False, diff=False, remove_old=False, remove_old_matching=None, all_possible=False, only_project=False): import re @@ -798,9 +807,8 @@ Macros: if "openmpi" in mpi: for of in openmpi_flavors: dependencies = ((project, compiler),) - if "mofed" in of: - dependencies = (("extern:" + of, distribution),) + dependencies - + if not parent: + dependencies = openmpi_flavor_dependencies(of, distribution) + dependencies repo(mpi + "_" + compiler + "_" + of, dependencies, mpi=True, mpi_repository=mpi, mpi_module=mpi_module(mpi), openmpi_flavor=of) @@ -823,8 +831,8 @@ Macros: "Prefer: mpcdf_" + cuda,)) for of in openmpi_flavors: dependencies = ((project, cuda + "_" + mpi + "_" + compiler),) - if "mofed" in of: - dependencies = (("extern:" + of, distribution),) + dependencies + if not parent: + dependencies = openmpi_flavor_dependencies(of, distribution) + dependencies repo(cuda + "_aware_" + mpi + "_" + compiler + "_" + of, dependencies, cuda_aware_mpi=True, openmpi_flavor=of, -- GitLab