diff options
author | Jan Luebbe <jlu@pengutronix.de> | 2012-09-06 12:20:15 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2012-09-06 19:31:49 +0200 |
commit | 606feec23625c1505c2ab28c084bccd23efdae36 (patch) | |
tree | 5e7227a744388a81ea992ff1c54fed0f54148942 /Makefile | |
parent | 25fc2ca049636274afcf65528ec07187d215cd27 (diff) | |
download | barebox-606feec23625c1505c2ab28c084bccd23efdae36.tar.gz barebox-606feec23625c1505c2ab28c084bccd23efdae36.tar.xz |
kbuild: keep the barebox binary accessible
When building a special image from the original (compressed or
not) binary, to not overwrite KBUILD_BINARY.
This allows producing multiple images (such as MLO, UBL, ...)
from the (z)barebox.bin. In the case where no special image is
used, KBUILD_IMAGE is set to KBUILD_BINARY.
This patch was developed together with Sascha Hauer. Thanks!
Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 16 |
1 files changed, 11 insertions, 5 deletions
@@ -462,12 +462,18 @@ CFLAGS += $(call cc-option,-Wdeclaration-after-statement,) # disable pointer signed / unsigned warnings in gcc 4.0 CFLAGS += $(call cc-option,-Wno-pointer-sign,) -# Default kernel image to build when no specific target is given. -# KBUILD_IMAGE may be overruled on the command line or -# set in the environment -# Also any assignments in arch/$(ARCH)/Makefile take precedence over -# this default value +# KBUILD_IMAGE: Default barebox image to build +# Depending on the architecture, this can be either compressed or not. +# It will also include any necessary headers to be bootable. export KBUILD_IMAGE ?= barebox.bin +# KBUILD_BINARY: Raw barebox binary +# This variable is set in case the architecture prepends a header and +# points to a binary that can be loaded directly into RAM and executed. +export KBUILD_BINARY ?= barebox.bin +# KBUILD_IMAGE and _BINARY may be overruled on the command line or +# set in the environment. +# Also any assignments in arch/$(ARCH)/Makefile take precedence over +# the default value. barebox-flash-image: $(KBUILD_IMAGE) $(call if_changed,ln) |