From 8320a2cbc9def3343984f98e88ad4174cab6537a Mon Sep 17 00:00:00 2001 From: Daniel Thompson Date: Thu, 29 Sep 2016 22:45:50 -0700 Subject: [PATCH] target: zephyr: Include toolchain headers using -isystem (#1381) Currently the zephyr port fails to build with some cross-toolsets because warnings from the system headers are being treated as errors. Using -isystem for any includes in TOOLCHAIN_CFLAGS allows us to crank up the warning levels without worrying about newlib headers breaking the build. JerryScript-DCO-1.0-Signed-off-by: Daniel Thompson daniel.thompson@linaro.org --- targets/zephyr/Makefile.zephyr | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/targets/zephyr/Makefile.zephyr b/targets/zephyr/Makefile.zephyr index c13088147..1b16d4717 100644 --- a/targets/zephyr/Makefile.zephyr +++ b/targets/zephyr/Makefile.zephyr @@ -114,10 +114,9 @@ CC = $(CROSS_COMPILE)gcc ZEPHYR_LIBC_INC = $(subst -I,,$(TOOLCHAIN_CFLAGS)) LIB_INCLUDE_DIR += -L $(CURDIR)/$(OUTPUT) -# TODO: There is a warning when compiling in some architectures related to __sputc_r EXT_CFLAGS += -Wno-error=conversion EXT_CFLAGS += $(LIB_INCLUDE_DIR) -EXT_CFLAGS += $(TOOLCHAIN_CFLAGS) +EXT_CFLAGS += $(subst -I,-isystem,$(TOOLCHAIN_CFLAGS)) EXTERNAL_LIB = $(INTERM)/lib/libjerry-core.a ZEPHYR_BIN = $(OUTPUT)/zephyr/zephyr.strip