forked from luck/tmp_suning_uos_patched
923f79743c
Pull kbuild changes from Michal Marek: - Unification of cmd_uimage among archs that use it - make headers_check tries harder before reporting a missing <linux/types.h> include - kbuild portability fix for shells that do not support echo -e - make clean descends into samples/ - setlocalversion grep fix - modpost typo fix - dtc warnings fix * 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild: setlocalversion: Use "grep -q" instead of piping output to "read dummy" modpost: fix ALL_INIT_DATA_SECTIONS Kbuild: centralize MKIMAGE and cmd_uimage definitions headers_check: recursively search for linux/types.h inclusion scripts/Kbuild.include: Fix portability problem of "echo -e" scripts: dtc: fix compile warnings kbuild: clean up samples directory kbuild: disable -Wmissing-field-initializers for W=1
55 lines
1.3 KiB
Makefile
55 lines
1.3 KiB
Makefile
#
|
|
# arch/microblaze/boot/Makefile
|
|
#
|
|
|
|
obj-y += linked_dtb.o
|
|
|
|
targets := linux.bin linux.bin.gz simpleImage.%
|
|
|
|
OBJCOPYFLAGS := -R .note -R .comment -R .note.gnu.build-id -O binary
|
|
|
|
# Ensure system.dtb exists
|
|
$(obj)/linked_dtb.o: $(obj)/system.dtb
|
|
|
|
# Generate system.dtb from $(DTB).dtb
|
|
ifneq ($(DTB),system)
|
|
$(obj)/system.dtb: $(obj)/$(DTB).dtb
|
|
$(call if_changed,cp)
|
|
endif
|
|
|
|
$(obj)/linux.bin: vmlinux FORCE
|
|
$(call if_changed,objcopy)
|
|
$(call if_changed,uimage)
|
|
@echo 'Kernel: $@ is ready' ' (#'`cat .version`')'
|
|
|
|
$(obj)/linux.bin.gz: $(obj)/linux.bin FORCE
|
|
$(call if_changed,gzip)
|
|
@echo 'Kernel: $@ is ready' ' (#'`cat .version`')'
|
|
|
|
quiet_cmd_cp = CP $< $@$2
|
|
cmd_cp = cat $< >$@$2 || (rm -f $@ && echo false)
|
|
|
|
quiet_cmd_strip = STRIP $@
|
|
cmd_strip = $(STRIP) -K microblaze_start -K _end -K __log_buf \
|
|
-K _fdt_start vmlinux -o $@
|
|
|
|
UIMAGE_IN = $@
|
|
UIMAGE_OUT = $@.ub
|
|
UIMAGE_LOADADDR = $(CONFIG_KERNEL_BASE_ADDR)
|
|
|
|
$(obj)/simpleImage.%: vmlinux FORCE
|
|
$(call if_changed,cp,.unstrip)
|
|
$(call if_changed,objcopy)
|
|
$(call if_changed,uimage)
|
|
$(call if_changed,strip)
|
|
@echo 'Kernel: $@ is ready' ' (#'`cat .version`')'
|
|
|
|
|
|
# Rule to build device tree blobs
|
|
DTC_FLAGS := -p 1024
|
|
|
|
$(obj)/%.dtb: $(src)/dts/%.dts FORCE
|
|
$(call if_changed_dep,dtc)
|
|
|
|
clean-files += *.dtb simpleImage.*.unstrip linux.bin.ub
|