X-Git-Url: https://git.archive.openwrt.org/?p=openwrt.git;a=blobdiff_plain;f=include%2Ftoplevel.mk;fp=include%2Ftoplevel.mk;h=0b5ac2686fd76e9a3298a4619079905e46f7cb09;hp=c8f342b48fc4e0476312d993060172fa7e52de57;hb=dcceaa431e3f44c1ea8611f3963afa02e27dbc34;hpb=bf4bf8754d429adccf5d2c3e057fa4aac8f05afa 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),)