summaryrefslogtreecommitdiff
path: root/target/u-boot
diff options
context:
space:
mode:
authorPeter Korsgaard <jacmet@sunsite.dk>2008-04-23 10:30:03 +0000
committerPeter Korsgaard <jacmet@sunsite.dk>2008-04-23 10:30:03 +0000
commitbb0a617e12e7113c37a8bf4d4fc65c19e9b2ad82 (patch)
treee27deff5d9a3b2a63f6dad3c972aa698149e8a60 /target/u-boot
parent7581683ef8773d827d2aa60871076f44b9386c6c (diff)
u-boot: set ARCH and CROSS_COMPILE
Diffstat (limited to 'target/u-boot')
-rw-r--r--target/u-boot/Makefile.in5
1 files changed, 4 insertions, 1 deletions
diff --git a/target/u-boot/Makefile.in b/target/u-boot/Makefile.in
index 3198a36a0..8d9b6e6a6 100644
--- a/target/u-boot/Makefile.in
+++ b/target/u-boot/Makefile.in
@@ -11,6 +11,8 @@ U_BOOT_PATCH_DIR:=$(PROJECT_BUILD_DIR)/u-boot-patches
U_BOOT_CAT:=$(BZCAT)
U_BOOT_BIN:=u-boot.bin
U_BOOT_TOOLS_BIN:=mkimage
+# u-boot still uses arch=ppc for powerpc
+U_BOOT_ARCH=$(echo $(KERNEL_ARCH)|$(SED) 's/powerpc/ppc/')
ifneq ($(BR2_TARGET_U_BOOT_CONFIG_BOARD),)
U_BOOT_INC_CONF_FILE:=$(U_BOOT_DIR)/include/configs/$(subst _config,,$(BR2_TARGET_U_BOOT_CONFIG_BOARD)).h
@@ -104,7 +106,8 @@ $(U_BOOT_DIR)/$(U_BOOT_BIN): $(U_BOOT_DIR)/.header_modified
$(TARGET_CONFIGURE_OPTS) \
CFLAGS="$(TARGET_CFLAGS)" \
LDFLAGS="$(TARGET_LDFLAGS)" \
- $(MAKE) -C $(U_BOOT_DIR)
+ $(MAKE) CROSS_COMPILE="$(TARGET_CROSS)" ARCH=$(KERNEL_ARCH) \
+ -C $(U_BOOT_DIR)
$(BINARIES_DIR)/$(U_BOOT_BIN): $(U_BOOT_DIR)/$(U_BOOT_BIN)
cp -dpf $(U_BOOT_DIR)/$(U_BOOT_BIN) $(BINARIES_DIR)