build: ensure rules with pipes might fail

.SHELLFLAGS is extended by option pipefail to make pipes fail if any pipe
element fails. As .SHELLFLAGS is exported into sub-make instances it
must be unexported before calling third-party build systems recursively.
This commit is contained in:
Christian Helmuth
2022-03-10 15:25:50 +01:00
committed by Norman Feske
parent 7da691b52a
commit d182b20705
16 changed files with 63 additions and 22 deletions

View File

@@ -9,6 +9,9 @@ CC_WARN += -Wno-array-bounds -Wno-unused-but-set-variable \
-Wno-parentheses -Wno-format -Wno-builtin-declaration-mismatch \
-Wno-unused-function -Wno-pointer-compare
# do not confuse third-party sub-makes
unexport .SHELLFLAGS
user_build.tag:
LIBGCCFLAGS="$(CC_MARCH)" \
LDFLAGS="$(addprefix $(LD_PREFIX),$(LD_MARCH)) -nostdlib" \

View File

@@ -24,6 +24,9 @@ $(KERNEL_BUILD_DIR)/Makefile:
#
unexport CCACHE
# do not confuse third-party sub-makes
unexport .SHELLFLAGS
#
# How to pass custom compiler flags to the Pistachio build system
#