uClibc as of 20090825 requires the ARCH to be specified when we call it's make
authorAustin Foxley <austinf@cetoncorp.com>
Thu, 3 Sep 2009 18:47:12 +0000 (11:47 -0700)
committerPeter Korsgaard <jacmet@sunsite.dk>
Thu, 3 Sep 2009 19:20:18 +0000 (21:20 +0200)
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
toolchain/uClibc/uclibc.mk

index de8e1d56238d07d3a296914a5524ca7f560b3337..764b503aa1c7dc17960f7d69b40cb133d9153072 100644 (file)
@@ -420,6 +420,7 @@ $(UCLIBC_DIR)/.config: $(UCLIBC_DIR)/.oldconfig
        mkdir -p $(TOOL_BUILD_DIR)/uClibc_dev/usr/lib
        mkdir -p $(TOOL_BUILD_DIR)/uClibc_dev/lib
        $(MAKE1) -C $(UCLIBC_DIR) \
+               ARCH="$(UCLIBC_TARGET_ARCH)" \
                PREFIX=$(TOOL_BUILD_DIR)/uClibc_dev/ \
                DEVEL_PREFIX=/usr/ \
                RUNTIME_PREFIX=$(TOOL_BUILD_DIR)/uClibc_dev/ \
@@ -429,6 +430,7 @@ $(UCLIBC_DIR)/.config: $(UCLIBC_DIR)/.oldconfig
 
 $(UCLIBC_DIR)/.configured: $(LINUX_HEADERS_DIR)/.configured $(UCLIBC_DIR)/.config
        set -x && $(MAKE1) -C $(UCLIBC_DIR) \
+               ARCH="$(UCLIBC_TARGET_ARCH)" \
                PREFIX=$(TOOL_BUILD_DIR)/uClibc_dev/ \
                DEVEL_PREFIX=/usr/ \
                RUNTIME_PREFIX=$(TOOL_BUILD_DIR)/uClibc_dev/ \
@@ -457,6 +459,7 @@ endif
 
 $(UCLIBC_DIR)/lib/libc.a: $(UCLIBC_DIR)/.configured $(gcc_initial) $(LIBFLOAT_TARGET)
        $(MAKE1) -C $(UCLIBC_DIR) \
+               ARCH="$(UCLIBC_TARGET_ARCH)" \
                PREFIX= \
                DEVEL_PREFIX=/ \
                RUNTIME_PREFIX=/ \
@@ -466,6 +469,7 @@ $(UCLIBC_DIR)/lib/libc.a: $(UCLIBC_DIR)/.configured $(gcc_initial) $(LIBFLOAT_TA
 
 uclibc-menuconfig: host-sed $(UCLIBC_DIR)/.config
        $(MAKE1) -C $(UCLIBC_DIR) \
+               ARCH="$(UCLIBC_TARGET_ARCH)" \
                PREFIX=$(TOOL_BUILD_DIR)/uClibc_dev/ \
                DEVEL_PREFIX=/usr/ \
                RUNTIME_PREFIX=$(TOOL_BUILD_DIR)/uClibc_dev/ \
@@ -477,12 +481,14 @@ uclibc-menuconfig: host-sed $(UCLIBC_DIR)/.config
 $(STAGING_DIR)/usr/lib/libc.a: $(UCLIBC_DIR)/lib/libc.a
 ifneq ($(BR2_TOOLCHAIN_SYSROOT),y)
        $(MAKE1) -C $(UCLIBC_DIR) \
+               ARCH="$(UCLIBC_TARGET_ARCH)" \
                PREFIX= \
                DEVEL_PREFIX=$(STAGING_DIR)/ \
                RUNTIME_PREFIX=$(STAGING_DIR)/ \
                install_runtime install_dev
 else
        $(MAKE1) -C $(UCLIBC_DIR) \
+               ARCH="$(UCLIBC_TARGET_ARCH)" \
                PREFIX=$(STAGING_DIR) \
                DEVEL_PREFIX=/usr/ \
                RUNTIME_PREFIX=/ \
@@ -525,6 +531,7 @@ endif
 ifneq ($(TARGET_DIR),)
 $(TARGET_DIR)/lib/libc.so.0: $(STAGING_DIR)/usr/lib/libc.a
        $(MAKE1) -C $(UCLIBC_DIR) \
+               ARCH="$(UCLIBC_TARGET_ARCH)" \
                PREFIX=$(TARGET_DIR) \
                DEVEL_PREFIX=/usr/ \
                RUNTIME_PREFIX=/ \
@@ -539,6 +546,7 @@ endif
 $(TARGET_DIR)/usr/bin/ldd: $(cross_compiler)
        $(MAKE1) -C $(UCLIBC_DIR) CC=$(TARGET_CROSS)gcc \
                CPP=$(TARGET_CROSS)cpp LD=$(TARGET_CROSS)ld \
+               ARCH="$(UCLIBC_TARGET_ARCH)" \
                PREFIX=$(TARGET_DIR) utils install_utils
 ifeq ($(BR2_CROSS_TOOLCHAIN_TARGET_UTILS),y)
        mkdir -p $(STAGING_DIR)/usr/$(REAL_GNU_TARGET_NAME)/target_utils
@@ -571,7 +579,7 @@ uclibc-configured: kernel-headers $(UCLIBC_DIR)/.configured
 uclibc-configured-source: uclibc-source
 
 uclibc-clean: uclibc-test-clean
-       -$(MAKE1) -C $(UCLIBC_DIR) clean
+       -$(MAKE1) -C $(UCLIBC_DIR) ARCH="$(UCLIBC_TARGET_ARCH)" clean
        rm -f $(UCLIBC_DIR)/.config
 
 uclibc-dirclean: uclibc-test-dirclean
@@ -613,6 +621,7 @@ uclibc-test-dirclean:
 
 $(TARGET_DIR)/usr/lib/libc.a: $(STAGING_DIR)/usr/lib/libc.a
        $(MAKE1) -C $(UCLIBC_DIR) \
+               ARCH="$(UCLIBC_TARGET_ARCH)" \
                PREFIX=$(TARGET_DIR) \
                DEVEL_PREFIX=/usr/ \
                RUNTIME_PREFIX=/ \