diff --git a/Makefile.common b/Makefile.common index e1881b62..1d6d9442 100644 --- a/Makefile.common +++ b/Makefile.common @@ -60,7 +60,7 @@ HOSTCFLAGS := -fstack-protector-strong -Wall -Werror -std=c11 -O2 -g HOSTCPPFLAGS := -I$(TOPDIR)/include HOSTLDFLAGS := HOSTLDLIBS := -HOSTAR := ar +HOSTAR := $(CONFIG_HOST_AR) define HOSTCOMPILE.c @echo "HOSTCC $@" diff --git a/configure.sh b/configure.sh index c38617b8..009d2603 100755 --- a/configure.sh +++ b/configure.sh @@ -57,7 +57,8 @@ Options: Environment variables affecting the build system configuration: HOST_CC - C compiler used for host tools and tenders. + HOST_AR + C compiler and ar tool used for host tools and tenders. TARGET_CC TARGET_LD @@ -247,6 +248,8 @@ done # # Configure host tools and tenders based on HOST_CC. # +HOST_AR=${HOST_AR:-ar} + HOST_CC=${HOST_CC:-cc} HOST_CC_MACHINE=$(${HOST_CC} -dumpmachine) [ $? -ne 0 ] && @@ -342,6 +345,7 @@ CONFIG_DISABLE_TOOLCHAIN=1 CONFIG_HOST_ARCH=${CONFIG_HOST_ARCH} CONFIG_HOST=${CONFIG_HOST} CONFIG_HOST_CC=${HOST_CC} +CONFIG_HOST_AR=${HOST_AR} CONFIG_HVT_TENDER_ENABLE_CAPSICUM=${CONFIG_HVT_TENDER_ENABLE_CAPSICUM} CONFIG_HVT_TENDER=${CONFIG_HVT_TENDER} CONFIG_SPT_TENDER=${CONFIG_SPT_TENDER} @@ -520,6 +524,7 @@ CONFIG_PREFIX=${OPT_PREFIX} CONFIG_HOST_ARCH=${CONFIG_HOST_ARCH} CONFIG_HOST=${CONFIG_HOST} CONFIG_HOST_CC=${HOST_CC} +CONFIG_HOST_AR=${HOST_AR} CONFIG_HVT=${CONFIG_HVT} CONFIG_HVT_TENDER_ENABLE_CAPSICUM=${CONFIG_HVT_TENDER_ENABLE_CAPSICUM} CONFIG_HVT_TENDER=${CONFIG_HVT_TENDER}