ARM: 7184/1: fix $(CROSS_COMPILE) prefix missing from size invocation
authorJanusz Krzysztofik <jkrzyszt@tis.icnet.pl>
Thu, 1 Dec 2011 21:45:47 +0000 (22:45 +0100)
committerRussell King <rmk+kernel@arm.linux.org.uk>
Tue, 3 Jan 2012 15:14:08 +0000 (15:14 +0000)
Otherwise, cross compilation may fail with error messages like:

...
size: arch/arm/boot/compressed/../../../../vmlinux: File format is ambiguous
size: Matching formats: elf32-littlearm elf32-littlearm-symbian elf32-littlearm-vxworks
  LD      arch/arm/boot/compressed/vmlinux
  arm-angstrom-linux-uclibcgnueabi-ld:--defsym _kernel_bss_size=: syntax error

Signed-off-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
arch/arm/boot/compressed/Makefile

index 21f56ff32797eaef80af79c49db60ce2c89912fa..cf0a64ce4b83ad73b21b5cd6d59ab4c96fc5f2f3 100644 (file)
@@ -126,7 +126,8 @@ ccflags-y := -fpic -fno-builtin -I$(obj)
 asflags-y := -Wa,-march=all
 
 # Supply kernel BSS size to the decompressor via a linker symbol.
-KBSS_SZ = $(shell size $(obj)/../../../../vmlinux | awk 'END{print $$3}')
+KBSS_SZ = $(shell $(CROSS_COMPILE)size $(obj)/../../../../vmlinux | \
+               awk 'END{print $$3}')
 LDFLAGS_vmlinux = --defsym _kernel_bss_size=$(KBSS_SZ)
 # Supply ZRELADDR to the decompressor via a linker symbol.
 ifneq ($(CONFIG_AUTO_ZRELADDR),y)