Skip to content
Snippets Groups Projects
Unverified Commit d2478af2 authored by Alexandre Abadie's avatar Alexandre Abadie Committed by GitHub
Browse files

Merge pull request #9821 from cladmi/pr/make/jerryscript/includes

pkg/jerryscript: fix jerryscript not using system includes
parents 4878cf21 04a91e9a
No related branches found
No related tags found
No related merge requests found
INCLUDES += -I$(PKGDIRBASE)/jerryscript/jerry-core/include
INCLUDES += -I$(PKGDIRBASE)/jerryscript/jerry-ext/include
ifneq (,$(filter cortex-m%,$(CPU_ARCH)))
# jerryscript package package is not using system includes right now, so
# many newlib hearders (not even stdio.h) is found
# Fixed in #9821 (so remove when merged)
TOOLCHAINS_BLACKLIST += llvm
endif
......@@ -6,6 +6,20 @@ EXT_CFLAGS :=-D__TARGET_RIOT
ifeq ($(TOOLCHAIN)_$(BOARD),llvm_native)
EXT_CFLAGS :=-D__TARGET_RIOT -Wno-conversion
else ifeq (esp32,$(CPU))
# The esp32 C newlib version 2.2.0 has errors when compiling with warnings
# that are enabled by jerryscript build system so disable them for this cpu:
# * -Wundef: stdio.h: `__GNU_VISIBLE` and `__BSD_VISIBLE` are not defined
EXT_CFLAGS += -Wno-undef -Wno-error=undef
else ifeq (esp8266,$(CPU))
# The esp8266 C newlib version 3.0.0 has errors when compiling with warnings
# that are enabled by jerryscript build system so disable them for this cpu:
# * -Wundef
# * -Wconversion
# * -Wsign-conversion
EXT_CFLAGS += -Wno-undef -Wno-error=undef
EXT_CFLAGS += -Wno-conversion -Wno-error=conversion
EXT_CFLAGS += -Wno-sign-conversion -Wno-error=sign-conversion
endif
.PHONY: all libjerry
......@@ -25,7 +39,7 @@ libjerry:
-DJERRY_LIBM=OFF \
-DJERRY_CMDLINE=OFF \
-DHAVE_TIME_H=0 \
-DEXTERNAL_COMPILE_FLAGS="$(EXT_CFLAGS)" \
-DEXTERNAL_COMPILE_FLAGS="$(INCLUDES) $(EXT_CFLAGS)" \
-DMEM_HEAP_SIZE_KB=$(JERRYHEAP)
"$(MAKE)" -C $(BUILD_DIR) jerry-core jerry-ext jerry-port-default-minimal
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment