diff --git a/sys/newlib/Makefile.include b/sys/newlib/Makefile.include index 78211041e..f7f24f624 100644 --- a/sys/newlib/Makefile.include +++ b/sys/newlib/Makefile.include @@ -36,4 +36,5 @@ ifeq (,$(NEWLIB_INCLUDES)) NEWLIB_INCLUDES := $(addprefix -isystem ,$(wildcard $(dir $(shell which $(PREFIX)gcc))../$(TARGET_TRIPLE)/include)) endif -export INCLUDES += $(NEWLIB_INCLUDES) +# Newlib includes should go before GCC includes. +export INCLUDES := $(NEWLIB_INCLUDES) $(INCLUDES)