uboot-mvebu: add support for espressobin
[openwrt/openwrt.git] / package / boot / uboot-mvebu / Makefile
1 #
2 # Copyright (C) 2016 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9 include $(INCLUDE_DIR)/kernel.mk
10
11 PKG_VERSION:=2020.10-rc4
12 PKG_RELEASE:=1
13
14 PKG_HASH:=0a7bdd2c7df2c14daf2730fcf3277fd917aadfaae935529e29c7412314bbf260
15
16 include $(INCLUDE_DIR)/u-boot.mk
17 include $(INCLUDE_DIR)/package.mk
18 include $(INCLUDE_DIR)/host-build.mk
19
20 define U-Boot/Default
21 BUILD_TARGET:=mvebu
22 HIDDEN:=1
23 endef
24
25 define U-Boot/clearfog
26 NAME:=SolidRun ClearFog A1
27 BUILD_DEVICES:=solidrun_clearfog-base-a1 solidrun_clearfog-pro-a1
28 BUILD_SUBTARGET:=cortexa9
29 UBOOT_IMAGE:=u-boot-spl.kwb
30 endef
31
32 define U-Boot/helios4
33 NAME:=Kobol Helios 4
34 BUILD_DEVICES:=kobol_helios4
35 BUILD_SUBTARGET:=cortexa9
36 UBOOT_IMAGE:=u-boot-spl.kwb
37 endef
38
39 define U-Boot/espressobin
40 NAME:=Marvell ESPRESSObin
41 BUILD_DEVICES:=globalscale_espressobin globalscale_espressobin-v7
42 BUILD_SUBTARGET:=cortexa53
43 UBOOT_CONFIG:=mvebu_espressobin-88f3720
44 endef
45
46 define U-Boot/espressobin-emmc
47 NAME:=Marvell ESPRESSObin
48 BUILD_DEVICES:=globalscale_espressobin-emmc globalscale_espressobin-v7-emmc
49 BUILD_SUBTARGET:=cortexa53
50 UBOOT_CONFIG:=mvebu_espressobin-88f3720
51 UBOOT_MAKE_FLAGS+=DEVICE_TREE=armada-3720-espressobin-emmc
52 endef
53
54 define U-Boot/uDPU
55 NAME:=Methode uDPU
56 BUILD_DEVICES:=methode_udpu
57 BUILD_SUBTARGET:=cortexa53
58 endef
59
60 UBOOT_TARGETS:= \
61 clearfog \
62 helios4 \
63 espressobin \
64 espressobin-emmc \
65 uDPU
66
67 Build/Exports:=$(Host/Exports)
68
69 define Build/Configure
70 # enable additional options beyond <device>_defconfig
71 echo CONFIG_NET_RANDOM_ETHADDR=y >> $(PKG_BUILD_DIR)/configs/$(UBOOT_CONFIG)_defconfig
72 echo CONFIG_CMD_SETEXPR=y >> $(PKG_BUILD_DIR)/configs/$(UBOOT_CONFIG)_defconfig
73
74 $(call Build/Configure/U-Boot)
75 endef
76
77 define Build/InstallDev
78 $(INSTALL_DIR) $(STAGING_DIR_IMAGE)
79 $(CP) $(PKG_BUILD_DIR)/$(UBOOT_IMAGE) $(STAGING_DIR_IMAGE)/$(BUILD_VARIANT)-$(UBOOT_IMAGE)
80 endef
81
82 $(eval $(call BuildPackage/U-Boot))