Lines Matching +full:extend +full:- +full:variant +full:- +full:schema
4 # SPDX-License-Identifier: Apache-2.0
23 BOARD_SCHEMA_PATH = str(Path(__file__).parent / 'schemas' / 'board-schema.yml')
53 class Variant: class
58 def from_dict(variant): argument
60 for v in variant.get('variants', []):
61 variants.append(Variant.from_dict(v))
62 return Variant(variant['name'], variants)
85 [Variant.from_dict(v) for v in variants if c == v['cpucluster']]
88 return Soc(soc.name, variants=[Variant.from_dict(v) for v in variants])
134 node = Variant(None)
142 node = Variant(None)
144 if node in (Soc(None), Variant(None)):
219 board_name = file_name[:-len('_defconfig')]
229 with board_yml.open('r', encoding='utf-8') as f:
239 if len(mutual_exclusive - b.keys()) < 1:
245 mutual_exclusive = {'name', 'extend'}
246 if len(mutual_exclusive - board.keys()) < 1:
251 if 'extend' in board:
272 if len(mutual_exclusive - board.keys()) < 1:
289 variants=[Variant.from_dict(v) for v in board.get('variants', [])],
302 board = boards.get(e['extend'])
311 sys.exit(f'ERROR: Variant: {v["name"]}, defined multiple times for board: '
313 node.variants.append(Variant.from_dict(v))
321 board_files.extend((root / 'boards').rglob(BOARD_YML))
338 board_files.extend((root / 'boards').rglob(BOARD_YML))
347 board_extensions.extend(e)
361 # Remember to update west-completion.bash if you add or remove
363 parser.add_argument("--arch-root", dest='arch_roots', default=[],
366 parser.add_argument("--board-root", dest='board_roots', default=[],
369 parser.add_argument("--soc-root", dest='soc_roots', default=[],
372 parser.add_argument("--board", dest='board', default=None,
374 parser.add_argument("--board-dir", default=[], type=Path, action='append',
379 parser.add_argument("--cmakeformat", default=None,
383 def variant_v2_qualifiers(variant, qualifiers = None): argument
384 qualifiers_list = [variant.name] if qualifiers is None else [qualifiers + '/' + variant.name]
385 for v in variant.variants:
386 qualifiers_list.extend(variant_v2_qualifiers(v, qualifiers_list[0]))
399 qualifiers_list.extend(variant_v2_qualifiers(v, id_str))
403 qualifiers_list.extend(variant_v2_qualifiers(v, s.name))
406 qualifiers_list.extend(variant_v2_qualifiers(v))