external toolchain: use LANG=C when calling gcc -v
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Thu, 16 Jul 2009 22:07:08 +0000 (00:07 +0200)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Thu, 16 Jul 2009 22:10:46 +0000 (00:10 +0200)
Lionel Landwerlin <lionel.landwerlin@openwide.fr> reported that using
the external toolchain support when LANG=fr_FR.UTF-8 doesn't work,
since the messages printed by gcc -v are translated in another
language, defeating the grep ^Configured test.

Therefore, as per Lionel suggestion, we force LANG=C when calling
$(TARGET_CC) -v.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
toolchain/external-toolchain/ext-tool.mk

index 7a0132ab1ddf3bac8596be6043c831f7f4458fbf..4cd4f2d4fb72cccbe451a18a74e86851bf6e58d5 100644 (file)
@@ -135,7 +135,7 @@ check_uclibc = \
 # configuration of the external toolchain.
 #
 check_arm_abi = \
-       EXT_TOOLCHAIN_TARGET=$(shell $(TARGET_CC) -v 2>&1 | grep ^Target | cut -f2 -d ' ') ; \
+       EXT_TOOLCHAIN_TARGET=$(shell LANG=C $(TARGET_CC) -v 2>&1 | grep ^Target | cut -f2 -d ' ') ; \
        if echo $${EXT_TOOLCHAIN_TARGET} | grep -q 'eabi$$' ; then \
                EXT_TOOLCHAIN_ABI="eabi" ; \
        else \
@@ -159,7 +159,7 @@ else
 EXTERNAL_LIBS+=ld-linux.so libnss_files.so
 endif
 
-SYSROOT_DIR=$(shell $(TARGET_CC) -v 2>&1 | grep ^Configured | tr " " "\n" | grep -- "--with-sysroot" | cut -f2 -d=)
+SYSROOT_DIR=$(shell LANG=C $(TARGET_CC) -v 2>&1 | grep ^Configured | tr " " "\n" | grep -- "--with-sysroot" | cut -f2 -d=)
 
 $(STAMP_DIR)/ext-toolchain-installed:
        @echo "Checking external toolchain settings"