From d44e4c1f7f506899b5044c9a1055f9093fc54a7f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABtan=20Harter?= Date: Fri, 8 Jun 2018 11:49:16 +0200 Subject: [PATCH 1/6] Makefile.include: only use board include directory if it exists Some boards do not have a boards/BOARD/include directory and rely on a board/common one. --- Makefile.include | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile.include b/Makefile.include index 7736b8dde5..fd1b23b066 100644 --- a/Makefile.include +++ b/Makefile.include @@ -229,7 +229,7 @@ export PREFIX ?= $(if $(TARGET_ARCH),$(TARGET_ARCH)-) # Add standard include directories INCLUDES += -I$(RIOTBASE)/core/include -I$(RIOTBASE)/drivers/include -I$(RIOTBASE)/sys/include INCLUDES += -I$(RIOTCPU)/$(CPU)/include -INCLUDES += -I$(RIOTBOARD)/$(BOARD)/include +INCLUDES += $(addprefix -I,$(wildcard $(RIOTBOARD)/$(BOARD)/include)) # process provided features -include $(RIOTBOARD)/$(BOARD)/Makefile.features From 07e7426160b6fbc179bc014e3817f939b2849731 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABtan=20Harter?= Date: Thu, 25 Jan 2018 15:45:38 +0100 Subject: [PATCH 2/6] pkg/libcoap: remove non existing include directory --- pkg/libcoap/Makefile.include | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pkg/libcoap/Makefile.include b/pkg/libcoap/Makefile.include index 73dd7ce3ce..969fda2c67 100644 --- a/pkg/libcoap/Makefile.include +++ b/pkg/libcoap/Makefile.include @@ -1,3 +1,2 @@ INCLUDES += -I$(PKGDIRBASE)/libcoap \ - -I$(RIOTBASE)/sys/posix/include \ - -I$(RIOTBASE)/sys/net/include + -I$(RIOTBASE)/sys/posix/include From a8e3b6846df5ed1d67712c47e3c3a63d32f29631 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABtan=20Harter?= Date: Mon, 11 Jun 2018 15:07:19 +0200 Subject: [PATCH 3/6] pkg/openthread: remove non existing include directory --- pkg/openthread/Makefile.include | 1 - 1 file changed, 1 deletion(-) diff --git a/pkg/openthread/Makefile.include b/pkg/openthread/Makefile.include index b4eebf4365..7fd2ba782f 100644 --- a/pkg/openthread/Makefile.include +++ b/pkg/openthread/Makefile.include @@ -1,7 +1,6 @@ OPENTHREAD_DIR = $(RIOTBASE)/pkg/openthread INCLUDES += -I$(OPENTHREAD_DIR)/include \ - -I$(OPENTHREAD_DIR)/include/openthread \ -I$(BINDIRBASE)/pkg/$(BOARD)/openthread/output/include \ -I$(BINDIRBASE)/pkg/$(BOARD)/openthread/include/openthread \ From 48143e93896df885bdbd812f250017b48c7653c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABtan=20Harter?= Date: Mon, 11 Jun 2018 15:12:34 +0200 Subject: [PATCH 4/6] pkg/tiny-asn1: remove non existing include directory In this Makefile, 'CURDIR' is RIOTBASE/pkg/tiny-asn1 directory which does not exist and not PKGDIRBASE/tiny-asn1. The correct include directory is set by pkg/tiny-asn1/Makefile.include. --- pkg/tiny-asn1/Makefile | 3 --- 1 file changed, 3 deletions(-) diff --git a/pkg/tiny-asn1/Makefile b/pkg/tiny-asn1/Makefile index 61a4bfbaec..3fa3640e9e 100644 --- a/pkg/tiny-asn1/Makefile +++ b/pkg/tiny-asn1/Makefile @@ -3,9 +3,6 @@ PKG_URL = https://gitlab.com/mtausig/tiny-asn1.git PKG_VERSION = 82e3a26273900b532e33e5b377f193fa08ee7d1b PKG_LICENSE = LGPL-3 -export TINYASN1_ROOT=$(CURDIR) -INCLUDES+=-I$(TINYASN1_ROOT)/src - .PHONY: all all: git-download From 726581fc2e2cc475b1dee63b608e4a0b62cccc67 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABtan=20Harter?= Date: Mon, 11 Jun 2018 15:15:45 +0200 Subject: [PATCH 5/6] sys/Makefile.include: remove non existing include directory The include/crypto path should include 'sys' to be vavil But all source files are already using '#include "crypto/HEADER.h"' so it does not need fixing. --- sys/Makefile.include | 4 ---- 1 file changed, 4 deletions(-) diff --git a/sys/Makefile.include b/sys/Makefile.include index baa5e0b298..55aa6793dc 100644 --- a/sys/Makefile.include +++ b/sys/Makefile.include @@ -6,10 +6,6 @@ ifneq (,$(filter cbor,$(USEMODULE))) USEMODULE_INCLUDES += $(RIOTBASE)/sys/cbor/include endif -ifneq (,$(filter crypto,$(USEMODULE))) - USEMODULE_INCLUDES += $(RIOTBASE)/include/crypto -endif - ifneq (,$(filter fib,$(USEMODULE))) USEMODULE_INCLUDES += $(RIOTBASE)/sys/posix/include endif From 08ff1b73a2bad0e82b7a52eb0a2b99f28956565e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABtan=20Harter?= Date: Thu, 25 Jan 2018 15:40:39 +0100 Subject: [PATCH 6/6] makefiles/cflags.inc.mk: add -Wmissing-include-dirs flag Warn if a user-supplied include directory does not exist. --- makefiles/cflags.inc.mk | 3 +++ 1 file changed, 3 insertions(+) diff --git a/makefiles/cflags.inc.mk b/makefiles/cflags.inc.mk index b35ddc98c5..34f878b79b 100644 --- a/makefiles/cflags.inc.mk +++ b/makefiles/cflags.inc.mk @@ -60,6 +60,9 @@ CFLAGS += -fno-common # Enable all default warnings CFLAGS += -Wall +# Warn if a user-supplied include directory does not exist. +CFLAGS += -Wmissing-include-dirs + ifeq (,$(filter -DDEVELHELP,$(CFLAGS))) ifneq (1,$(FORCE_ASSERTS)) CFLAGS += -DNDEBUG