blob: f66472fa9c298c5e1167c2d92e5bfff920204b05 [file] [log] [blame]
b.liue9582032025-04-17 19:18:16 +08001#
2# Copyright (C) 2016 Microchip Technology Inc.
3# <Sandeepsheriker.mallikarjun@microchip.com>
4#
5# This is free software, licensed under the GNU General Public License v2.
6# See /LICENSE for more information.
7#
8
9include $(TOPDIR)/rules.mk
10
11PKG_NAME:=at91bootstrap
12PKG_VERSION:=v3.9.3
13PKG_RELEASE:=2
14
15PKG_SOURCE_PROTO:=git
16PKG_SOURCE_URL:=https://github.com/linux4sam/at91bootstrap.git
17PKG_MIRROR_HASH:=06753d673756edc9753932db00f4e5b8c1f9fa7708337c4d6ce280573efb86b4
18PKG_SOURCE_VERSION:=d96833a4b6680b237708eb4dc9f10708b9e709d8
19PKG_BUILD_DIR = \
20 $(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
21
22include at91bootstrap.mk
23include $(INCLUDE_DIR)/package.mk
24
25define AT91Bootstrap/Default
26 BUILD_TARGET:=at91
27 HIDDEN:=1
28 AT91BOOTSTRAP_IMAGE:=at91bootstrap.bin
29endef
30
31define AT91Bootstrap/at91sam9x5eknf_uboot
32 NAME:=AT91Bootstrap for AT91SAM9X5-EK board (NandFlash)
33 BUILD_SUBTARGET:=sam9x
34 BUILD_DEVICES:=atmel_at91sam9x25ek atmel_at91sam9x35ek
35endef
36
37define AT91Bootstrap/at91sam9x5eksd_uboot
38 NAME:=AT91Bootstrap for AT91SAM9X5-EK board (SDcard)
39 BUILD_SUBTARGET:=sam9x
40 BUILD_DEVICES:=atmel_at91sam9x25ek atmel_at91sam9x35ek
41endef
42
43define AT91Bootstrap/sama5d2_xplaineddf_uboot
44 TITLE:=AT91Bootstrap for SAMA5D2 Xplained board (SPI Flash)
45 BUILD_SUBTARGET:=sama5
46 BUILD_DEVICES:=microchip_sama5d2-xplained
47endef
48
49define AT91Bootstrap/sama5d2_xplaineddf_qspi_uboot
50 TITLE:=AT91Bootstrap for SAMA5D2 Xplained board (QSPI Flash)
51 BUILD_SUBTARGET:=sama5
52 BUILD_DEVICES:=microchip_sama5d2-xplained
53endef
54
55define AT91Bootstrap/sama5d2_xplainedsd_uboot
56 TITLE:=AT91Bootstrap for SAMA5D2 Xplained board (SDcard/EMMC)
57 BUILD_SUBTARGET:=sama5
58 BUILD_DEVICES:=microchip_sama5d2-xplained
59endef
60
61define AT91Bootstrap/sama5d3_xplainednf_uboot
62 TITLE:=AT91Bootstrap for SAMA5D3 Xplained board (Nand Flash)
63 BUILD_SUBTARGET:=sama5
64 BUILD_DEVICES:=microchip_sama5d3-xplained
65endef
66
67define AT91Bootstrap/sama5d3_xplainedsd_uboot
68 TITLE:=AT91Bootstrap for SAMA5D3 Xplained board (SDcard)
69 BUILD_SUBTARGET:=sama5
70 BUILD_DEVICES:=microchip_sama5d3-xplained
71endef
72
73define AT91Bootstrap/sama5d4_xplainednf_uboot_secure
74 TITLE:=AT91Bootstrap for SAMA5D4 Xplained board (Nand Flash)
75 BUILD_SUBTARGET:=sama5
76 BUILD_DEVICES:=microchip_sama5d4-xplained
77endef
78
79define AT91Bootstrap/sama5d4_xplaineddf_uboot_secure
80 TITLE:=AT91Bootstrap for SAMA5D4 Xplained board (SPI Flash)
81 BUILD_SUBTARGET:=sama5
82 BUILD_DEVICES:=microchip_sama5d4-xplained
83endef
84
85define AT91Bootstrap/sama5d4_xplainedsd_uboot_secure
86 TITLE:=AT91Bootstrap for SAMA5D4 Xplained board (SDcard)
87 BUILD_SUBTARGET:=sama5
88 BUILD_DEVICES:=microchip_sama5d4-xplained
89endef
90
91define AT91Bootstrap/sama5d27_som1_eksd_uboot
92 TITLE:=AT91Bootstrap for SAMA5D27 SOM1 Ek (SDcard0)
93 BUILD_SUBTARGET:=sama5
94 BUILD_DEVICES:=microchip_sama5d27-som1-ek
95endef
96
97define AT91Bootstrap/sama5d27_som1_eksd1_uboot
98 TITLE:=AT91Bootstrap for SAMA5D27 SOM1 Ek (SDcard1)
99 BUILD_SUBTARGET:=sama5
100 BUILD_DEVICES:=microchip_sama5d27-som1-ek
101endef
102
103define AT91Bootstrap/sama5d27_som1_ekqspi_uboot
104 TITLE:=AT91Bootstrap for SAMA5D27 SOM1 Ek (QSPI Flash)
105 BUILD_SUBTARGET:=sama5
106 BUILD_DEVICES:=microchip_sama5d27-som1-ek
107endef
108
109define AT91Bootstrap/sama5d2_ptc_eknf_uboot
110 TITLE:=AT91Bootstrap for SAMA5D2 PTC EK (Nand Flash)
111 BUILD_SUBTARGET:=sama5
112 BUILD_DEVICES:=microchip_sama5d2-ptc-ek
113endef
114
115define AT91Bootstrap/sama5d2_ptc_eksd_uboot
116 TITLE:=AT91Bootstrap for SAMA5D2 PTC EK (SDCard)
117 BUILD_SUBTARGET:=sama5
118 BUILD_DEVICES:=microchip_sama5d2-ptc-ek
119endef
120
121AT91BOOTSTRAP_TARGETS := \
122 at91sam9x5eknf_uboot \
123 at91sam9x5eksd_uboot \
124 sama5d2_xplaineddf_uboot \
125 sama5d2_xplaineddf_qspi_uboot \
126 sama5d2_xplainedsd_uboot \
127 sama5d3_xplainednf_uboot \
128 sama5d3_xplainedsd_uboot \
129 sama5d4_xplainednf_uboot_secure \
130 sama5d4_xplaineddf_uboot_secure \
131 sama5d4_xplainedsd_uboot_secure \
132 sama5d27_som1_eksd1_uboot \
133 sama5d27_som1_ekqspi_uboot \
134 sama5d2_ptc_eknf_uboot \
135 sama5d2_ptc_eksd_uboot
136
137define Build/Compile
138 +$(MAKE) $(PKG_JOBS) -C $(PKG_BUILD_DIR) \
139 CROSS_COMPILE=$(TARGET_CROSS)
140endef
141
142$(eval $(call BuildPackage/AT91Bootstrap))