diff options
-rw-r--r-- | include/toplevel.mk | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/toplevel.mk b/include/toplevel.mk index c8f342b48f..0b5ac2686f 100644 --- a/include/toplevel.mk +++ b/include/toplevel.mk @@ -39,6 +39,13 @@ unexport LPATH # make sure that a predefined CFLAGS variable does not disturb packages export CFLAGS= +empty:= +space:= $(empty) $(empty) +path:=$(subst :,$(space),$(PATH)) +path:=$(filter-out .%,$(path)) +path:=$(subst $(space),:,$(path)) +export PATH:=$(path) + unexport TAR_OPTIONS ifneq ($(shell $(HOSTCC) 2>&1 | grep clang),) |