diff options
author | Yoshinori Sato <ysato@users.sourceforge.jp> | 2015-05-11 02:26:40 +0900 |
---|---|---|
committer | Yoshinori Sato <ysato@users.sourceforge.jp> | 2015-06-23 13:35:52 +0900 |
commit | 06706c96ed753f952e53fa9840fb38852d2fe37e (patch) | |
tree | b0c870e788d6f94d608d4b18d3fa9c002b2252fe /arch/h8300/boot/compressed/Makefile | |
parent | df2078b8daa7bb15cc8e3f791389b9f44e12bb25 (diff) | |
download | blackbird-op-linux-06706c96ed753f952e53fa9840fb38852d2fe37e.tar.gz blackbird-op-linux-06706c96ed753f952e53fa9840fb38852d2fe37e.zip |
h8300: compressed image support
Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
Diffstat (limited to 'arch/h8300/boot/compressed/Makefile')
-rw-r--r-- | arch/h8300/boot/compressed/Makefile | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/arch/h8300/boot/compressed/Makefile b/arch/h8300/boot/compressed/Makefile new file mode 100644 index 000000000000..87d03b7ee97e --- /dev/null +++ b/arch/h8300/boot/compressed/Makefile @@ -0,0 +1,37 @@ +# +# linux/arch/sh/boot/compressed/Makefile +# +# create a compressed vmlinux image from the original vmlinux +# + +targets := vmlinux vmlinux.bin vmlinux.bin.gz head.o misc.o piggy.o + +OBJECTS = $(obj)/head.o $(obj)/misc.o + +# +# IMAGE_OFFSET is the load offset of the compression loader +# Assign dummy values if these 2 variables are not defined, +# in order to suppress error message. +# +CONFIG_MEMORY_START ?= 0x00400000 +CONFIG_BOOT_LINK_OFFSET ?= 0x00140000 +IMAGE_OFFSET := $(shell printf "0x%08x" $$(($(CONFIG_MEMORY_START)+$(CONFIG_BOOT_LINK_OFFSET)))) + +LIBGCC := $(shell $(CROSS-COMPILE)$(CC) $(KBUILD_CFLAGS) -print-libgcc-file-name) +LDFLAGS_vmlinux := -Ttext $(IMAGE_OFFSET) -estartup $(obj)/vmlinux.lds + +$(obj)/vmlinux: $(OBJECTS) $(obj)/piggy.o $(LIBGCC) FORCE + $(call if_changed,ld) + @: + +$(obj)/vmlinux.bin: vmlinux FORCE + $(call if_changed,objcopy) + +$(obj)/vmlinux.bin.gz: $(obj)/vmlinux.bin FORCE + $(call if_changed,gzip) + +LDFLAGS_piggy.o := -r --format binary --oformat elf32-h8300-linux -T +OBJCOPYFLAGS := -O binary + +$(obj)/piggy.o: $(obj)/vmlinux.scr $(obj)/vmlinux.bin.gz FORCE + $(call if_changed,ld) |