diff options
Diffstat (limited to 'scripts/Makefile.lib')
-rw-r--r-- | scripts/Makefile.lib | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib index 00c368c6e996..0be6f110cce7 100644 --- a/scripts/Makefile.lib +++ b/scripts/Makefile.lib | |||
@@ -304,6 +304,30 @@ cmd_lzo = (cat $(filter-out FORCE,$^) | \ | |||
304 | lzop -9 && $(call size_append, $(filter-out FORCE,$^))) > $@ || \ | 304 | lzop -9 && $(call size_append, $(filter-out FORCE,$^))) > $@ || \ |
305 | (rm -f $@ ; false) | 305 | (rm -f $@ ; false) |
306 | 306 | ||
307 | # U-Boot mkimage | ||
308 | # --------------------------------------------------------------------------- | ||
309 | |||
310 | MKIMAGE := $(srctree)/scripts/mkuboot.sh | ||
311 | |||
312 | # SRCARCH just happens to match slightly more than ARCH (on sparc), so reduces | ||
313 | # the number of overrides in arch makefiles | ||
314 | UIMAGE_ARCH ?= $(SRCARCH) | ||
315 | UIMAGE_COMPRESSION ?= $(if $(2),$(2),none) | ||
316 | UIMAGE_OPTS-y ?= | ||
317 | UIMAGE_TYPE ?= kernel | ||
318 | UIMAGE_LOADADDR ?= arch_must_set_this | ||
319 | UIMAGE_ENTRYADDR ?= $(UIMAGE_LOADADDR) | ||
320 | UIMAGE_NAME ?= 'Linux-$(KERNELRELEASE)' | ||
321 | UIMAGE_IN ?= $< | ||
322 | UIMAGE_OUT ?= $@ | ||
323 | |||
324 | quiet_cmd_uimage = UIMAGE $(UIMAGE_OUT) | ||
325 | cmd_uimage = $(CONFIG_SHELL) $(MKIMAGE) -A $(UIMAGE_ARCH) -O linux \ | ||
326 | -C $(UIMAGE_COMPRESSION) $(UIMAGE_OPTS-y) \ | ||
327 | -T $(UIMAGE_TYPE) \ | ||
328 | -a $(UIMAGE_LOADADDR) -e $(UIMAGE_ENTRYADDR) \ | ||
329 | -n $(UIMAGE_NAME) -d $(UIMAGE_IN) $(UIMAGE_OUT) | ||
330 | |||
307 | # XZ | 331 | # XZ |
308 | # --------------------------------------------------------------------------- | 332 | # --------------------------------------------------------------------------- |
309 | # Use xzkern to compress the kernel image and xzmisc to compress other things. | 333 | # Use xzkern to compress the kernel image and xzmisc to compress other things. |