uboot-rockchip: introduce dependencies check for swig and pyelftools
Our *cute* users often ignore README so add dependencies check for it.
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
(cherry picked from commit 8cd920a8c5)
This commit is contained in:
parent
7c761808c3
commit
787ac7f653
@ -1,3 +1,5 @@
|
||||
include $(INCLUDE_DIR)/prereq.mk
|
||||
|
||||
PKG_NAME ?= u-boot
|
||||
|
||||
ifndef PKG_SOURCE_PROTO
|
||||
@ -18,6 +20,22 @@ PKG_LICENSE_FILES:=Licenses/README
|
||||
|
||||
PKG_BUILD_PARALLEL:=1
|
||||
|
||||
ifdef UBOOT_USE_BINMAN
|
||||
$(eval $(call TestHostCommand,python3-pyelftools, \
|
||||
Please install the Python3 elftools module, \
|
||||
$(STAGING_DIR_HOST)/bin/python3 -c 'import elftools'))
|
||||
endif
|
||||
|
||||
ifdef UBOOT_USE_INTREE_DTC
|
||||
$(eval $(call SetupHostCommand,swig,Please install 'swig', \
|
||||
swig -version))
|
||||
|
||||
$(eval $(call TestHostCommand,libpython3-dev, \
|
||||
Please install the libpython3-dev package, \
|
||||
$(STAGING_DIR_HOST)/bin/python3 -c 'import os; import sysconfig; \
|
||||
os.path.exists(sysconfig.get_paths()["include"] + "/Python.h") or exit(1)'))
|
||||
endif
|
||||
|
||||
export GCC_HONOUR_COPTS=s
|
||||
|
||||
define Package/u-boot/install/default
|
||||
@ -85,7 +103,9 @@ define Build/Configure/U-Boot
|
||||
+$(MAKE) $(PKG_JOBS) -C $(PKG_BUILD_DIR) $(UBOOT_CONFIGURE_VARS) $(UBOOT_CONFIG)_config
|
||||
endef
|
||||
|
||||
DTC=$(wildcard $(LINUX_DIR)/scripts/dtc/dtc)
|
||||
ifndef UBOOT_USE_INTREE_DTC
|
||||
DTC=$(wildcard $(LINUX_DIR)/scripts/dtc/dtc)
|
||||
endif
|
||||
|
||||
define Build/Compile/U-Boot
|
||||
+$(MAKE) $(PKG_JOBS) -C $(PKG_BUILD_DIR) \
|
||||
|
||||
@ -12,12 +12,13 @@ PKG_HASH:=e31cac91545ff41b71cec5d8c22afd695645cd6e2a442ccdacacd60534069341
|
||||
|
||||
PKG_MAINTAINER:=Tobias Maedel <openwrt@tbspace.de>
|
||||
|
||||
UBOOT_USE_BINMAN:=1
|
||||
UBOOT_USE_INTREE_DTC:=1
|
||||
|
||||
include $(INCLUDE_DIR)/u-boot.mk
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
include ../arm-trusted-firmware-rockchip/atf-version.mk
|
||||
|
||||
DTC:=
|
||||
|
||||
define U-Boot/Default
|
||||
BUILD_TARGET:=rockchip
|
||||
UENV:=default
|
||||
@ -196,6 +197,15 @@ UBOOT_MAKE_FLAGS += \
|
||||
BL31=$(STAGING_DIR_IMAGE)/$(ATF) \
|
||||
$(if $(DDR),ROCKCHIP_TPL=$(STAGING_DIR_IMAGE)/$(DDR))
|
||||
|
||||
define Build/Configure
|
||||
$(call Build/Configure/U-Boot)
|
||||
|
||||
sed -i $(PKG_BUILD_DIR)/.config \
|
||||
-e 's#CONFIG_MKIMAGE_DTC_PATH=.*#CONFIG_MKIMAGE_DTC_PATH="$(PKG_BUILD_DIR)/scripts/dtc/dtc"#g' \
|
||||
-e 's|CONFIG_SPL_FIT_SIGNATURE=y|# CONFIG_SPL_FIT_SIGNATURE is not set|g' \
|
||||
-e 's|CONFIG_TOOLS_MKEFICAPSULE=y|# CONFIG_TOOLS_MKEFICAPSULE is not set|g'
|
||||
endef
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(STAGING_DIR_IMAGE)
|
||||
ifneq ($(DDR),)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user