From 28b79191d46f2b83b1806fdf8697f0a5370b289d Mon Sep 17 00:00:00 2001 From: Vinicius Costa Gomes Date: Fri, 18 Dec 2015 18:40:30 -0200 Subject: [PATCH] build: Fix not allowing the host tools to be crosscompiled There are situations that the host gcc is not able to generate x86 binaries, in those cases, the user should point HOSTCC to a binary able to generate the correct type of binaries. This also allows './scripts/sanitycheck' to be run in systems where the build tools are prefixed by default. Change-Id: Id1fc247f8a820e19bb3d4e8119634f8300e7ebac Signed-off-by: Vinicius Costa Gomes --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 10571db2078..90f7433d7e2 100644 --- a/Makefile +++ b/Makefile @@ -267,8 +267,8 @@ CONFIG_SHELL := $(shell if [ -x "$$BASH" ]; then echo $$BASH; \ else if [ -x /bin/bash ]; then echo /bin/bash; \ else echo sh; fi ; fi) -HOSTCC = gcc -HOSTCXX = g++ +HOSTCC ?= gcc +HOSTCXX ?= g++ HOSTCFLAGS = -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89 HOSTCXXFLAGS = -O2