xref: /OK3568_Linux_fs/buildroot/package/vboot-utils/vboot-utils.mk (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1################################################################################
2#
3# vboot-utils
4#
5################################################################################
6
7VBOOT_UTILS_VERSION = bbdd62f9b030db7ad8eef789aaf58a7ff9a25656
8VBOOT_UTILS_SITE = https://chromium.googlesource.com/chromiumos/platform/vboot_reference
9VBOOT_UTILS_SITE_METHOD = git
10VBOOT_UTILS_LICENSE = BSD-3-Clause
11VBOOT_UTILS_LICENSE_FILES = LICENSE
12
13HOST_VBOOT_UTILS_DEPENDENCIES = host-openssl host-util-linux host-pkgconf
14
15# vboot_reference contains code that goes into bootloaders,
16# utilities intended for the target system, and a bunch of scripts
17# for Chromium OS build system. Most of that does not make sense
18# in a buildroot host-package.
19#
20# We only need futility for signing images, the keys, and cgpt for boot
21# media partitioning.
22#
23# make target for futility is "futil".
24#
25# The value of ARCH is only relevant for crossystem (a target tool) and
26# does not affect futil or cgpt in any way as long as it is one of the
27# supported targets.
28
29define HOST_VBOOT_UTILS_BUILD_CMDS
30	$(HOST_MAKE_ENV) $(MAKE) -C $(@D) \
31		CC="$(HOSTCC)" \
32		CFLAGS="$(HOST_CFLAGS) -D_LARGEFILE64_SOURCE -D_GNU_SOURCE" \
33		LDFLAGS="$(HOST_LDFLAGS)" \
34		ARCH=arm \
35		futil cgpt
36endef
37
38define HOST_VBOOT_UTILS_INSTALL_CMDS
39	$(HOST_MAKE_ENV) $(MAKE) -C $(@D) DESTDIR=$(HOST_DIR) \
40		futil_install cgpt_install devkeys_install
41endef
42
43$(eval $(host-generic-package))
44