]> git.baikalelectronics.ru Git - uboot.git/commit
binman: Add support for bintools
authorSimon Glass <sjg@chromium.org>
Mon, 10 Jan 2022 03:13:49 +0000 (20:13 -0700)
committerSimon Glass <sjg@chromium.org>
Tue, 25 Jan 2022 19:36:11 +0000 (12:36 -0700)
commita1888fde92f5d3354bfb4d8cdcbf27406cb5aff9
tree60c10dce7b90cdfd76ee4ec2fcefefabc7993a10
parentbe62bc3ddd06265dba7c2e2da471b1e7dfabc17e
binman: Add support for bintools

Binman requires various tools to actually work, such as 'lz4' to compress
data and 'futility' to sign Chrome OS firmware. At present these are
handled in an ad-hoc manner and there is no easy way to find out what
tools are needd to build an image, nor where to obtain them.

Add an implementation of 'bintool', a base class which implements this
functionality. When a bintool is required, it can be requested from this
module, then executed. When the tool is missing, it can provide a way to
obtain it.

Note that this uses Command directly, not the tools.Run() function. This
allows proper handling of missing tools and avoids needing to catch and
re-raise exceptions.

Signed-off-by: Simon Glass <sjg@chromium.org>
tools/binman/bintool.py [new file with mode: 0644]