aboutsummaryrefslogtreecommitdiff
path: root/package/imx-mkimage/imx-mkimage.mk
blob: 06d3157dc17d12d8ff84c50fbc72d65e0431f015 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
################################################################################
#
# imx-mkimage
#
################################################################################

IMX_MKIMAGE_VERSION = rel_imx_4.14.78_1.0.0_ga
IMX_MKIMAGE_SITE = https://source.codeaurora.org/external/imx/imx-mkimage
IMX_MKIMAGE_SITE_METHOD = git
IMX_MKIMAGE_LICENSE = GPL-2.0+
IMX_MKIMAGE_LICENSE_FILES = iMX8dv/COPYING
HOST_IMX_MKIMAGE_DEPENDENCIES = host-zlib

ifeq ($(BR2_PACKAGE_FREESCALE_IMX_PLATFORM_IMX8M),y)
# i.MX8M needs a different binary
define HOST_IMX_MKIMAGE_BUILD_CMDS
	$(HOST_MAKE_ENV) $(MAKE) $(HOST_CONFIGURE_OPTS) -C $(@D)/iMX8M -f soc.mak mkimage_imx8
endef
define HOST_IMX_MKIMAGE_INSTALL_CMDS
	$(INSTALL) -D -m 755 $(@D)/iMX8M/mkimage_imx8 $(HOST_DIR)/bin/mkimage_imx8
	$(INSTALL) -D -m 755 $(@D)/iMX8M/mkimage_fit_atf.sh $(HOST_DIR)/bin/mkimage_fit_atf.sh
endef
else
# i.MX8 and i.MX8X
define HOST_IMX_MKIMAGE_BUILD_CMDS
	$(HOST_MAKE_ENV) $(MAKE) $(HOST_CONFIGURE_OPTS) -C $(@D) MKIMG=mkimage_imx8 mkimage_imx8
endef
define HOST_IMX_MKIMAGE_INSTALL_CMDS
	$(INSTALL) -D -m 755 $(@D)/mkimage_imx8 $(HOST_DIR)/bin/mkimage_imx8
endef
endif

$(eval $(host-generic-package))