[1/6] package/uboot-tools: add host mkfwumdata support
Commit Message
Add an option to build and install the mkfwumdata tool on the host.
mkfwumdata generates the raw image of the FWU (Firmware Update)
metadata, which is needed for the initial installation of the FWU
multi bank update on the board.
The tool is linked against libuuid, hence the dependency on
host-util-linux. To avoid adding this dependency to all the users of
host-uboot-tools, the tool is built only when explicitly selected.
Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
---
package/uboot-tools/Config.in.host | 10 ++++++++++
package/uboot-tools/uboot-tools.mk | 9 +++++++++
2 files changed, 19 insertions(+)
@@ -39,6 +39,16 @@ config BR2_PACKAGE_HOST_UBOOT_TOOLS_FIT_SIGNATURE_SUPPORT
endif # BR2_PACKAGE_HOST_UBOOT_TOOLS_FIT_SUPPORT
+config BR2_PACKAGE_HOST_UBOOT_TOOLS_MKFWUMDATA
+ bool "mkfwumdata"
+ help
+ Install the mkfwumdata tool on the host system
+
+ The mkfwumdata tool from Das U-Boot bootloader, which allows
+ generation of the raw image of the FWU (Firmware Update)
+ metadata, for initial installation of the FWU multi bank
+ update on the board.
+
config BR2_PACKAGE_HOST_UBOOT_TOOLS_ENVIMAGE
bool "Environment image"
help
@@ -157,6 +157,14 @@ define HOST_UBOOT_TOOLS_INSTALL_FIT_CHECK_SIGN
endef
endif
+ifeq ($(BR2_PACKAGE_HOST_UBOOT_TOOLS_MKFWUMDATA),y)
+HOST_UBOOT_TOOLS_MAKE_OPTS += CONFIG_TOOLS_MKFWUMDATA=y
+HOST_UBOOT_TOOLS_DEPENDENCIES += host-util-linux
+define HOST_UBOOT_TOOLS_INSTALL_MKFWUMDATA
+ $(INSTALL) -m 0755 -D $(@D)/tools/mkfwumdata $(HOST_DIR)/bin/mkfwumdata
+endef
+endif
+
ifeq ($(BR2_PACKAGE_HOST_UBOOT_TOOLS_ENVIMAGE),y)
UBOOT_TOOLS_GENERATE_ENV_FILE = $(call qstrip,$(BR2_PACKAGE_HOST_UBOOT_TOOLS_ENVIMAGE_SOURCE))
@@ -241,6 +249,7 @@ define HOST_UBOOT_TOOLS_INSTALL_CMDS
$(INSTALL) -m 0755 -D $(@D)/tools/mkenvimage $(HOST_DIR)/bin/mkenvimage
$(INSTALL) -m 0755 -D $(@D)/tools/dumpimage $(HOST_DIR)/bin/dumpimage
$(HOST_UBOOT_TOOLS_INSTALL_FIT_CHECK_SIGN)
+ $(HOST_UBOOT_TOOLS_INSTALL_MKFWUMDATA)
$(INSTALL) -m 0755 -D $(@D)/tools/env/fw_printenv $(HOST_DIR)/bin/fw_printenv
ln -sf fw_printenv $(HOST_DIR)/bin/fw_setenv
$(HOST_UBOOT_TOOLS_INSTALL_ENVIMAGE)