diff options
author | bnewbold <bnewbold@robocracy.org> | 2013-07-14 23:56:45 +0000 |
---|---|---|
committer | bnewbold <bnewbold@robocracy.org> | 2013-07-14 23:56:45 +0000 |
commit | 6b2a0e0c9b297396a9c0841905fa31275a38a0e3 (patch) | |
tree | d064c70cea5ffb3b026d5896ee3494e6996a78a6 /boot/uboot/uboot.mk | |
parent | 4ddff0099fa0619cfd1bcf5afa96f56a703de385 (diff) | |
download | buildroot-novena-6b2a0e0c9b297396a9c0841905fa31275a38a0e3.tar.gz buildroot-novena-6b2a0e0c9b297396a9c0841905fa31275a38a0e3.zip |
u-boot: workaround for setlocalversion issue
The u-boot build process attempts to determine the version number using git
commands, which assumes that the build is taking place in a git checkout with
the .git directory intact. The buildroot build process does a git checkout, but
then exports a .tar.gz as a cache and does the build from that tarball (with no
.git file).
In some instances, being unable to determine the current version causes the
build process to generate a non-functional bootloader.
This patch implements a work-around for this problem by allowing the user to
configure a 'localverion' override which gets written to the ./localversion
file in the u-boot build directory, which is later used by the
./tools/setlocalversion script.
Diffstat (limited to 'boot/uboot/uboot.mk')
-rw-r--r-- | boot/uboot/uboot.mk | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/boot/uboot/uboot.mk b/boot/uboot/uboot.mk index b357e0f06..d384d1286 100644 --- a/boot/uboot/uboot.mk +++ b/boot/uboot/uboot.mk @@ -40,6 +40,8 @@ else ifeq ($(BR2_TARGET_UBOOT_FORMAT_NAND_BIN),y) UBOOT_BIN = u-boot-nand.bin else ifeq ($(BR2_TARGET_UBOOT_FORMAT_IMG),y) UBOOT_BIN = u-boot.img +else ifeq ($(BR2_TARGET_UBOOT_FORMAT_IMX),y) +UBOOT_BIN = u-boot.imx else UBOOT_BIN = u-boot.bin UBOOT_BIN_IFT = $(UBOOT_BIN).ift @@ -74,6 +76,9 @@ UBOOT_POST_PATCH_HOOKS += UBOOT_APPLY_CUSTOM_PATCHES endif define UBOOT_CONFIGURE_CMDS + $(if $(BR2_TARGET_UBOOT_CUSTOM_GIT), + $(if $(BR2_TARGET_UBOOT_CUSTOM_GIT_LOCALVERSION), + @echo $(BR2_TARGET_UBOOT_CUSTOM_GIT_LOCALVERSION) > $(@D)/localversion )) $(TARGET_CONFIGURE_OPTS) $(UBOOT_CONFIGURE_OPTS) \ $(MAKE) -C $(@D) $(UBOOT_MAKE_OPTS) \ $(UBOOT_BOARD_NAME)_config |