diff --git a/board/common/uboot/uboot.mk b/board/common/uboot/uboot.mk index cd8f4b2a..63f65d7e 100644 --- a/board/common/uboot/uboot.mk +++ b/board/common/uboot/uboot.mk @@ -46,3 +46,12 @@ define UBOOT_PRE_BUILD_INSTALL_ENV $(@D)/arch/$(UBOOT_ARCH)/dts/ endef UBOOT_PRE_BUILD_HOOKS += UBOOT_PRE_BUILD_INSTALL_ENV + +# Stamp non-release builds so they cannot be mistaken for a release, +# U-Boot's setlocalversion picks up .scmversion, see issue #919. +define UBOOT_PRE_BUILD_DEVEL_VERSION + echo "-DEVEL" >$(@D)/.scmversion +endef +ifeq ($(INFIX_RELEASE),) +UBOOT_PRE_BUILD_HOOKS += UBOOT_PRE_BUILD_DEVEL_VERSION +endif