summaryrefslogtreecommitdiff
path: root/boot/uboot
diff options
context:
space:
mode:
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>2015-04-26 11:51:15 +0200
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>2015-04-26 21:43:25 +0200
commitfa6289bb1aad1a8b6721fbeb15d34520c84dcb39 (patch)
tree3ca90cb1d78a38f1ffb920f7185657b84fa12212 /boot/uboot
parent256f142bf662fd8fee712e38edd58bb6e8fd283d (diff)
packages: refactor checks using BR_BUILDING
Instead of manually testing MAKECMDGOALS, use the newly introduced BR_BUILDING variable to know if we're building or not. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Tested-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Diffstat (limited to 'boot/uboot')
-rw-r--r--boot/uboot/uboot.mk13
1 files changed, 4 insertions, 9 deletions
diff --git a/boot/uboot/uboot.mk b/boot/uboot/uboot.mk
index 1526177b3..01aaf2cb0 100644
--- a/boot/uboot/uboot.mk
+++ b/boot/uboot/uboot.mk
@@ -164,8 +164,7 @@ define UBOOT_INSTALL_OMAP_IFT_IMAGE
endef
ifeq ($(BR2_TARGET_UBOOT_OMAP_IFT),y)
-# we NEED a config file unless we're at make source
-ifeq ($(filter source,$(MAKECMDGOALS)),)
+ifeq ($(BR_BUILDING),y)
ifeq ($(call qstrip,$(BR2_TARGET_UBOOT_OMAP_IFT_CONFIG)),)
$(error No gpsign config file. Check your BR2_TARGET_UBOOT_OMAP_IFT_CONFIG setting)
endif
@@ -179,8 +178,7 @@ UBOOT_POST_INSTALL_IMAGES_HOOKS += UBOOT_INSTALL_OMAP_IFT_IMAGE
endif
ifeq ($(BR2_TARGET_UBOOT_ENVIMAGE),y)
-# we NEED a environment settings unless we're at make source
-ifeq ($(filter source,$(MAKECMDGOALS)),)
+ifeq ($(BR_BUILDING),y)
ifeq ($(call qstrip,$(BR2_TARGET_UBOOT_ENVIMAGE_SOURCE)),)
$(error Please define a source file for Uboot environment (BR2_TARGET_UBOOT_ENVIMAGE_SOURCE setting))
endif
@@ -193,9 +191,7 @@ endif
$(eval $(generic-package))
-ifeq ($(BR2_TARGET_UBOOT),y)
-# we NEED a board name unless we're at make source
-ifeq ($(filter source,$(MAKECMDGOALS)),)
+ifeq ($(BR2_TARGET_UBOOT)$(BR_BUILDING),yy)
ifeq ($(UBOOT_BOARD_NAME),)
$(error No U-Boot board name set. Check your BR2_TARGET_UBOOT_BOARDNAME setting)
endif
@@ -221,5 +217,4 @@ $(error No custom U-Boot repository URL specified. Check your BR2_TARGET_UBOOT_C
endif # qstrip BR2_TARGET_UBOOT_CUSTOM_CUSTOM_REPO_VERSION
endif # BR2_TARGET_UBOOT_CUSTOM_GIT || BR2_TARGET_UBOOT_CUSTOM_HG
-endif # filter source
-endif # BR2_TARGET_UBOOT
+endif # BR2_TARGET_UBOOT && BR_BUILDING