diff options
author | Justin Ledford <justinledford@google.com> | 2022-03-25 03:27:17 +0300 |
---|---|---|
committer | Patrick Williams <patrick@stwcx.xyz> | 2022-03-28 17:02:04 +0300 |
commit | b4de16d6aa084adec80d4aefef0517eecae6a745 (patch) | |
tree | f1ff869f75682cada825d304942341557cc09c1b | |
parent | 971257a70909e5289359f8ed8c7b2ad53ff718ae (diff) | |
download | openbmc-b4de16d6aa084adec80d4aefef0517eecae6a745.tar.xz |
image_types_phosphor: Add compatible name to MANIFEST
This adds CompatibleNames field to the manifest file which can contain
compatibility strings as described in the Software interface.
The field is set by the OBMC_COMPATIBLE_NAMES variable in the
machine.conf file, e.g.
OBMC_COMPATIBLE_NAMES = "\
foo.bar \
baz.bim \
"
Also omit ExtendedVersion from the manifest file if it is not set.
Signed-off-by: Justin Ledford <justinledford@google.com>
Change-Id: Id27b4d6ec25ec7c3d3d5942368f40e618535eafe
-rw-r--r-- | meta-phosphor/classes/image_types_phosphor.bbclass | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/meta-phosphor/classes/image_types_phosphor.bbclass b/meta-phosphor/classes/image_types_phosphor.bbclass index 64fec000ba..206b080206 100644 --- a/meta-phosphor/classes/image_types_phosphor.bbclass +++ b/meta-phosphor/classes/image_types_phosphor.bbclass @@ -504,12 +504,17 @@ python do_generate_phosphor_manifest() { version = do_get_version(d) build_id = do_get_buildID(d) target_machine = d.getVar('MACHINE', True) - extended_version = (d.getVar('EXTENDED_VERSION', True) or "") + extended_version = d.getVar('EXTENDED_VERSION', True) + compatible_names = d.getVar('OBMC_COMPATIBLE_NAMES', True) with open('MANIFEST', 'w') as fd: fd.write('purpose={}\n'.format(purpose)) fd.write('version={}\n'.format(version.strip('"'))) fd.write('BuildId={}\n'.format(build_id.strip('"'))) - fd.write('ExtendedVersion={}\n'.format(extended_version)) + if extended_version: + fd.write('ExtendedVersion={}\n'.format(extended_version)) + if compatible_names: + for name in compatible_names.split(): + fd.write('CompatibleName={}\n'.format(name)) fd.write('KeyType={}\n'.format(get_pubkey_type(d))) fd.write('HashType=RSA-SHA256\n') fd.write('MachineName={}\n'.format(target_machine)) |