From 304e5a69bfad4826b13b821170bb574e847d9ce5 Mon Sep 17 00:00:00 2001 From: Gil Pitney Date: Tue, 1 Nov 2016 10:11:06 -0700 Subject: [PATCH] Makefile: Fix clobber of LIB_INCLUDE_DIR during second pass The commit: commit f25ac092b91b03eb231ee340e5eeffe52f14989e "Makefile: Restructure for multilibs" breaks external HAL library linking, by overriding, in the the second Makefile pass, the LIB_INCLUDE_DIR variable set in the first Makefile pass from ext/hal Makefiles. This breaks use of the CONFIG_CC3200SDK_LIBRARY=y option in the cc3200 SDK, and also likely the QMSI ext/hal/qmsi/Makefile, when CONFIG_QMSI_LIBRARY=y is set. This commit just changes the '=' to "+=". Jira: ZEP-1163 Change-Id: I1aaaaee57378dcd01ab6f2ed4799281b2337eea2 Signed-off-by: Gil Pitney --- scripts/Makefile.toolchain.zephyr | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/Makefile.toolchain.zephyr b/scripts/Makefile.toolchain.zephyr index a8a54c36bb9..b964abf6b62 100644 --- a/scripts/Makefile.toolchain.zephyr +++ b/scripts/Makefile.toolchain.zephyr @@ -71,7 +71,7 @@ endif LIBGCC_DIR = $(shell dirname `$(CROSS_COMPILE)gcc --sysroot=$(SYSROOT) $(KBUILD_CFLAGS) -print-libgcc-file-name`) NEWLIB_DIR = $(shell $(CROSS_COMPILE)gcc --sysroot=$(SYSROOT) $(KBUILD_CFLAGS) -print-multi-directory) TOOLCHAIN_CFLAGS = -I $(SYSROOT)/usr/include -LIB_INCLUDE_DIR = -L $(LIBGCC_DIR) -L $(SYSROOT)/usr/lib/$(NEWLIB_DIR) +LIB_INCLUDE_DIR += -L $(LIBGCC_DIR) -L $(SYSROOT)/usr/lib/$(NEWLIB_DIR) endif ifneq ($(CONFIG_TOOLCHAIN_VARIANT:"%"=%),)