Merge branch 'linux_next' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab...
[platform/adaptation/renesas_rcar/renesas_kernel.git] / arch / arc / boot / Makefile
1 targets := vmlinux.bin vmlinux.bin.gz uImage
2
3 # uImage build relies on mkimage being availble on your host for ARC target
4 # You will need to build u-boot for ARC, rename mkimage to arc-elf32-mkimage
5 # and make sure it's reacable from your PATH
6 MKIMAGE := $(srctree)/scripts/mkuboot.sh
7
8 OBJCOPYFLAGS= -O binary -R .note -R .note.gnu.build-id -R .comment -S
9
10 LINUX_START_TEXT = $$(readelf -h vmlinux | \
11                         grep "Entry point address" | grep -o 0x.*)
12
13 UIMAGE_LOADADDR    = $(CONFIG_LINUX_LINK_BASE)
14 UIMAGE_ENTRYADDR   = $(LINUX_START_TEXT)
15 UIMAGE_COMPRESSION = gzip
16
17 $(obj)/vmlinux.bin: vmlinux FORCE
18         $(call if_changed,objcopy)
19
20 $(obj)/vmlinux.bin.gz: $(obj)/vmlinux.bin FORCE
21         $(call if_changed,gzip)
22
23 $(obj)/uImage: $(obj)/vmlinux.bin.gz FORCE
24         $(call if_changed,uimage)
25
26 PHONY += FORCE