Explorar o código

build: uImage: allow override of default arguments

For some build recipes, the argument to Build/uImage is used to sneak in
extra arguments for mkimage, whereas this appears to have been intended
to specificy the compression method only.

Use the first provided word for -C to be backwards compatible with
current calls to Build/uImage. Use the rest of the call arguments to
override the provided defaults. Only the input file name (-d) and the
output file name cannot overriden.

Signed-off-by: Sander Vanheule <[email protected]>
Sander Vanheule %!s(int64=5) %!d(string=hai) anos
pai
achega
ff012f3a67
Modificáronse 1 ficheiros con 3 adicións e 2 borrados
  1. 3 2
      include/image-commands.mk

+ 3 - 2
include/image-commands.mk

@@ -396,8 +396,9 @@ endef
 define Build/uImage
 	mkimage -A $(LINUX_KARCH) \
 		-O linux -T kernel \
-		-C $(1) -a $(KERNEL_LOADADDR) -e $(if $(KERNEL_ENTRY),$(KERNEL_ENTRY),$(KERNEL_LOADADDR)) \
-		-n '$(if $(UIMAGE_NAME),$(UIMAGE_NAME),$(call toupper,$(LINUX_KARCH)) $(VERSION_DIST) Linux-$(LINUX_VERSION))' -d $@ [email protected]
+		-C $(word 1,$(1)) -a $(KERNEL_LOADADDR) -e $(if $(KERNEL_ENTRY),$(KERNEL_ENTRY),$(KERNEL_LOADADDR)) \
+		-n '$(if $(UIMAGE_NAME),$(UIMAGE_NAME),$(call toupper,$(LINUX_KARCH)) $(VERSION_DIST) Linux-$(LINUX_VERSION))' \
+		$(wordlist 2,$(words $(1)),$(1)) -d $@ [email protected]
 	mv [email protected] $@
 endef