Skip to content

Commit e09915b

Browse files
committed
(config/legacy/build.py): Add architecture option
Unfortunately we are still using legacy parser for build_configs, so we need to add here architectures option for limiting tree, to build only specific architectures. Signed-off-by: Denys Fedoryshchenko <denys.f@collabora.com>
1 parent 19374e1 commit e09915b

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

kernelci/legacy/config/build.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,7 @@ class BuildConfig(YAMLConfigObject):
359359

360360
yaml_tag = u'!BuildConfig'
361361

362-
def __init__(self, name, tree, branch, variants, reference=None):
362+
def __init__(self, name, tree, branch, variants, reference=None, architectures=None):
363363
"""A build configuration defines the actual kernels to be built.
364364
365365
*name* is the name of the build configuration. It is arbitrary and
@@ -384,6 +384,7 @@ def __init__(self, name, tree, branch, variants, reference=None):
384384
self._branch = branch
385385
self._variants = variants
386386
self._reference = reference
387+
self._architectures = architectures
387388

388389
@classmethod
389390
def load_from_yaml(cls, config, name, trees, fragments, b_envs, defaults):
@@ -404,6 +405,7 @@ def load_from_yaml(cls, config, name, trees, fragments, b_envs, defaults):
404405
reference = config.get('reference', defaults.get('reference'))
405406
if reference:
406407
kw['reference'] = Reference.load_from_yaml(reference, trees)
408+
kw['architectures'] = config.get('architectures', None)
407409
return cls(**kw)
408410

409411
@property
@@ -422,6 +424,10 @@ def branch(self):
422424
def variants(self):
423425
return list(self._variants.values())
424426

427+
@property
428+
def architectures(self):
429+
return self._architectures
430+
425431
def get_variant(self, name):
426432
return self._variants[name]
427433

0 commit comments

Comments
 (0)