From a5b2af1baf7c65cb2fa83684ff7b905458cfe0cf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABtan=20Harter?= Date: Fri, 27 Jul 2018 21:01:55 +0200 Subject: [PATCH] Makefile.include: Fix BUILDRELPATH when RIOTPROJECT is CURDIR. This fixes building an example that is outside of RIOT with docker and also fixes building from a release archive. --- Makefile.include | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Makefile.include b/Makefile.include index 351406751d..66c1b5d45f 100644 --- a/Makefile.include +++ b/Makefile.include @@ -66,7 +66,8 @@ endif MAKEOVERRIDES += $(foreach v,$(__DIRECTORY_VARIABLES),$(v)=$($(v))) # Path to the current directory relative to RIOTPROJECT -BUILDRELPATH ?= $(CURDIR:$(RIOTPROJECT)/%=%)/ +# trailing '/' is important when RIOTPROJECT == CURDIR +BUILDRELPATH ?= $(patsubst $(RIOTPROJECT)/%,%,$(CURDIR)/) # get host operating system OS := $(shell uname)