nios2: generate kernel image in Intel HEX format
Altera tools for creating .pof files for flashing onto their FPGAs require UFM data to be in this special format. Extend the current 'all' and 'zephyr' targets to additionally create this .hex file using objcopy, with the same exclusions as the existing rule for .bin files. Change-Id: I75293fba47536545359f817a1f2c1ae905b9d25c Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
This commit is contained in:
parent
31e8030c05
commit
fe6f178a3b
|
@ -29,3 +29,17 @@ soc-aflags ?= $(soc-cflags)
|
|||
KBUILD_CFLAGS += $(soc-cflags)
|
||||
KBUILD_CXXFLAGS += $(soc-cxxflags)
|
||||
KBUILD_AFLAGS += $(soc-aflags)
|
||||
|
||||
KERNEL_HEX_NAME = $(KERNEL_NAME).hex
|
||||
|
||||
quiet_cmd_gen_hex = HEX $@
|
||||
cmd_gen_hex = \
|
||||
( \
|
||||
$(OBJCOPY) -S -O ihex -R .note -R .comment -R COMMON -R .eh_frame $< $@; \
|
||||
)
|
||||
|
||||
$(KERNEL_HEX_NAME): $(KERNEL_ELF_NAME)
|
||||
$(call cmd,gen_hex)
|
||||
|
||||
zephyr: $(KERNEL_HEX_NAME)
|
||||
all: $(KERNEL_HEX_NAME)
|
||||
|
|
Loading…
Reference in a new issue