diff --git a/pkg/relic/Makefile b/pkg/relic/Makefile index f9e74e895c..667fc201f0 100644 --- a/pkg/relic/Makefile +++ b/pkg/relic/Makefile @@ -15,6 +15,11 @@ CFLAGS += -Wno-unused-function -Wno-old-style-definition -Wno-unused-parameter \ -Wno-pedantic -Wno-array-parameter -Wno-unused-but-set-variable \ -Wno-stringop-overflow +ifeq (llvm,$(TOOLCHAIN)) + CFLAGS += $(GCC_C_INCLUDES) + CXXFLAGS += $(GCC_CXX_INCLUDES) +endif + TOOLCHAIN_FILE = $(PKG_SOURCE_DIR)/xcompile-toolchain.cmake all: $(BINDIR)/$(PKG_NAME).a diff --git a/pkg/relic/Makefile.include b/pkg/relic/Makefile.include index bbcfce1ccb..f94915aee0 100644 --- a/pkg/relic/Makefile.include +++ b/pkg/relic/Makefile.include @@ -1,10 +1,3 @@ INCLUDES += -I$(PKGDIRBASE)/relic/include INCLUDES += -I$(BINDIR)/pkg-build/relic/include ARCHIVES += $(BINDIR)/relic.a - -ifneq (,$(filter cortex-m%,$(CPU_CORE))) - # relic package package is not using system includes right now, so - # many newlib headers (not even stdio.h) are not found. - # Fixed in #9821 for jerryscript, should be applicable here too. - TOOLCHAINS_BLACKLIST += llvm -endif diff --git a/pkg/relic/patches/0003-fix-Wformat-nonliteral-by-using-printf-directly.patch b/pkg/relic/patches/0003-fix-Wformat-nonliteral-by-using-printf-directly.patch new file mode 100644 index 0000000000..c258cead27 Binary files /dev/null and b/pkg/relic/patches/0003-fix-Wformat-nonliteral-by-using-printf-directly.patch differ