v2: -Change SRC_AARCH32_GCC unchanged -set AARCH32_GCC_VERSION to gcc-linaro-6.2.1-2016.11-i686_arm-linux-gnueabihf.tar.xz
Support building optee on 32-bit Host Linux distribution
Signed-off-by: Prasanna K Mutharaju prasannakarthik@outlook.com --- toolchain.mk | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/toolchain.mk b/toolchain.mk index 33c6dfb..e588f7c 100644 --- a/toolchain.mk +++ b/toolchain.mk @@ -4,9 +4,14 @@ ROOT ?= $(CURDIR)/.. TOOLCHAIN_ROOT ?= $(ROOT)/toolchains
+LBITS := $(shell getconf LONG_BIT) AARCH32_PATH ?= $(TOOLCHAIN_ROOT)/aarch32 AARCH32_CROSS_COMPILE ?= $(AARCH32_PATH)/bin/arm-linux-gnueabihf- -AARCH32_GCC_VERSION ?= gcc-linaro-6.2.1-2016.11-x86_64_arm-linux-gnueabihf +ifeq ($(LBITS),64) + AARCH32_GCC_VERSION ?= gcc-linaro-6.2.1-2016.11-x86_64_arm-linux-gnueabihf +else + AARCH32_GCC_VERSION ?= gcc-linaro-6.2.1-2016.11-i686_arm-linux-gnueabihf +endif SRC_AARCH32_GCC ?= http://releases.linaro.org/components/toolchain/binaries/6.2-2016.11/arm-lin...
AARCH64_PATH ?= $(TOOLCHAIN_ROOT)/aarch64