waf: Build all BSPs with -k with errors

Closes #5252
This commit is contained in:
Chris Johns
2025-05-29 17:57:38 +10:00
parent 34c362fee1
commit ef07c0c540

19
wscript
View File

@@ -51,6 +51,7 @@ default_prefix = "/opt/rtems/" + version["__RTEMS_MAJOR__"]
compilers = ["gcc", "clang"] compilers = ["gcc", "clang"]
items = {} items = {}
bsps = {} bsps = {}
variant_errors = []
def get_repo_release_label(ctx): def get_repo_release_label(ctx):
@@ -1442,7 +1443,7 @@ def configure_version(conf):
if int(version["__RTEMS_REVISION__"]) != 0: if int(version["__RTEMS_REVISION__"]) != 0:
v_str += "." + version["__RTEMS_REVISION__"] v_str += "." + version["__RTEMS_REVISION__"]
if version_label is not None and version_label != "": if version_label is not None and version_label != "":
v_str += "." + version_label v_str += "." + version_label
conf.msg("Configure RTEMS version", v_str, color="YELLOW") conf.msg("Configure RTEMS version", v_str, color="YELLOW")
@@ -1633,9 +1634,23 @@ def append_variant_builds(bld):
UninstallContext): UninstallContext):
name = c.__name__.replace("Context", "").lower() name = c.__name__.replace("Context", "").lower()
class magic(c): class rtems_context(c):
cmd = name + "_" + var cmd = name + "_" + var
variant = var variant = var
last_variant = var == bld.env["VARIANTS"][-1]
def compile(self):
global variant_errors
try:
super().compile()
except:
variant_errors += [self.variant]
if not self.keep:
raise
if self.keep and self.last_variant and len(
variant_errors) > 0:
raise self.fatal('error: BSP(s) in errors: ' +
' '.join(variant_errors))
waflib.Options.commands.append(bld.cmd + "_" + var) waflib.Options.commands.append(bld.cmd + "_" + var)