summaryrefslogtreecommitdiff
path: root/spec/spec/build-option.yml
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2023-01-17 15:10:29 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2023-01-23 07:26:05 +0100
commitb91e7f2d98dae3605019428b19f2db476430543f (patch)
tree3cea9bb5ee95256038f34526f76f7815825c831a /spec/spec/build-option.yml
parentdfd57e945e636c009dc07f965cd76f63d575cb64 (diff)
spec: Improve build option default values
Merge "default" and "default-by-variant" attributes. Use an enabled-by expression to select the default value.
Diffstat (limited to 'spec/spec/build-option.yml')
-rw-r--r--spec/spec/build-option.yml35
1 files changed, 13 insertions, 22 deletions
diff --git a/spec/spec/build-option.yml b/spec/spec/build-option.yml
index cff5446d..346b9818 100644
--- a/spec/spec/build-option.yml
+++ b/spec/spec/build-option.yml
@@ -17,17 +17,17 @@ spec-example: |
- define: null
build-type: option
copyrights:
- - Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)
- default: 115200
- default-by-variant:
- - value: 9600
- variants:
+ - Copyright (C) 2020, 2022 embedded brains GmbH (http://www.embedded-brains.de)
+ default:
+ - enabled-by:
- bsps/powerpc/motorola_powerpc
- m68k/m5484FireEngine
- powerpc/hsc_cm01
- - value: 19200
- variants:
- - m68k/COBRA5475
+ value: 9600
+ - enabled-by: m68k/COBRA5475
+ value: 19200
+ - enabled-by: true
+ value: 115200
description: |
Default baud for console and other serial devices.
enabled-by: true
@@ -48,19 +48,11 @@ spec-info:
spec-type: build-action-list
default:
description: |
- It shall be the default value of the option if no variant-specific
- default value is specified. Use ``null`` to specify that no default
- value exits. The variant-specific default values may be specified by
- the ``default-by-variant`` attribute.
- spec-type: build-option-value
- default-by-variant:
- description: |
- The list is checked two times and processed from top to bottom.
- Firstly, the base BSP name is used to match with a variant.
- Secondly, the BSP family name prefixed by ``bsps/`` is used to match
- with a variant. If a matching variant is found, then the processing
- stops.
- spec-type: build-default-by-variant-list
+ It shall be the list of default values of the option. When a default
+ value is needed, the first value on the list which is enabled
+ according to the enabled set is choosen. If no value is enabled,
+ then the default value is ``null``.
+ spec-type: build-default-value-list
description:
description: |
It shall be the description of the option.
@@ -79,7 +71,6 @@ spec-info:
mandatory-attributes:
- actions
- default
- - default-by-variant
- description
spec-name: Build Option Item Type
spec-type: build-option