cmake.mk: set C/CXX compiler for host builds as well

Without this, cmake will use whatever CC/CXX is set to, which could be
clang. In that case, at least libjson-c/host will fail to compile.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
Rosen Penev 2020-11-25 16:08:57 -08:00 committed by Petr Štetiar
parent 796d51834c
commit f98878e4c1
1 changed files with 2 additions and 0 deletions

View File

@ -97,6 +97,8 @@ define Host/Configure/Default
LDFLAGS="$(HOST_LDFLAGS)" \
cmake \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_C_COMPILER="$(HOSTCC)" \
-DCMAKE_CXX_COMPILER="$(HOSTCXX)" \
-DCMAKE_C_FLAGS_RELEASE="-DNDEBUG" \
-DCMAKE_CXX_FLAGS_RELEASE="-DNDEBUG" \
-DCMAKE_EXE_LINKER_FLAGS:STRING="$(HOST_LDFLAGS)" \