2022-03-04 08:39:04 +00:00
|
|
|
# SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
include $(INCLUDE_DIR)/kernel.mk
|
|
|
|
|
2023-05-17 13:08:40 +00:00
|
|
|
PKG_RELEASE:=1
|
2022-03-04 08:39:04 +00:00
|
|
|
|
|
|
|
PKG_SOURCE_PROTO:=git
|
|
|
|
PKG_SOURCE_URL:=https://git.openwrt.org/project/bcm63xx/u-boot.git
|
2022-12-08 11:01:43 +00:00
|
|
|
PKG_SOURCE_DATE:=2022-12-08
|
|
|
|
PKG_SOURCE_VERSION:=4435700d18a791dca0d8d767e5414dfac9df4451
|
2024-04-07 10:29:11 +00:00
|
|
|
PKG_MIRROR_HASH:=80de483c11938cca9fdd0f35931cce1921c8166d9c1c146da56bf155394842cb
|
2022-03-04 08:39:04 +00:00
|
|
|
|
|
|
|
include $(INCLUDE_DIR)/u-boot.mk
|
|
|
|
include $(INCLUDE_DIR)/package.mk
|
|
|
|
|
|
|
|
define U-Boot/Default
|
|
|
|
BUILD_TARGET:=bcm4908
|
|
|
|
UBOOT_IMAGE:=u-boot-nodtb.bin
|
|
|
|
DEFAULT:=y
|
|
|
|
endef
|
|
|
|
|
|
|
|
define U-Boot/bcm4908
|
|
|
|
NAME:=Broadcom's BCM4908
|
|
|
|
UBOOT_CONFIG:=bcm94908
|
2022-07-20 11:47:06 +00:00
|
|
|
SOC:=bcm4908
|
2022-03-04 08:39:04 +00:00
|
|
|
endef
|
|
|
|
|
2022-03-15 17:41:03 +00:00
|
|
|
define U-Boot/bcm4912
|
|
|
|
NAME:=Broadcom's BCM4912
|
|
|
|
UBOOT_CONFIG:=bcm94912
|
2022-07-20 11:47:06 +00:00
|
|
|
SOC:=bcm4912
|
2022-03-15 17:41:03 +00:00
|
|
|
endef
|
|
|
|
|
2022-03-04 08:39:04 +00:00
|
|
|
UBOOT_TARGETS := \
|
2022-03-15 17:41:03 +00:00
|
|
|
bcm4908 \
|
|
|
|
bcm4912
|
2022-03-04 08:39:04 +00:00
|
|
|
|
|
|
|
define Build/Prepare
|
|
|
|
$(call Build/Prepare/Default)
|
|
|
|
mkdir -p $(PKG_BUILD_DIR)/include/generated/
|
|
|
|
( cd $(PKG_BUILD_DIR)/board/broadcom/bcmbca/httpd/html/ && \
|
2022-03-15 11:40:40 +00:00
|
|
|
$(STAGING_DIR_HOST)/bin/xxd -i index.html > ../../../../../include/generated/index.h && \
|
|
|
|
$(STAGING_DIR_HOST)/bin/xxd -i flashing.html > ../../../../../include/generated/flashing.h && \
|
|
|
|
$(STAGING_DIR_HOST)/bin/xxd -i fail.html > ../../../../../include/generated/fail.h && \
|
|
|
|
$(STAGING_DIR_HOST)/bin/xxd -i 404.html > ../../../../../include/generated/404.h )
|
2022-03-04 08:39:04 +00:00
|
|
|
endef
|
|
|
|
|
|
|
|
define Build/InstallDev
|
|
|
|
$(INSTALL_DIR) $(STAGING_DIR_IMAGE)/u-boot
|
2022-07-20 11:47:06 +00:00
|
|
|
$(INSTALL_BIN) $(PKG_BUILD_DIR)/$(UBOOT_IMAGE) $(STAGING_DIR_IMAGE)/u-boot/u-boot-$(SOC).bin
|
|
|
|
$(INSTALL_BIN) $(PKG_BUILD_DIR)/u-boot.dtb $(STAGING_DIR_IMAGE)/u-boot/u-boot-$(SOC).dtb
|
2022-03-04 08:39:04 +00:00
|
|
|
$(INSTALL_BIN) $(PKG_BUILD_DIR)/arch/arm/dts/*.dtb $(STAGING_DIR_IMAGE)/u-boot/
|
|
|
|
endef
|
|
|
|
|
|
|
|
$(eval $(call BuildPackage/U-Boot))
|