From 9fc8689db8ad00ab1bcb5e9c47fd43c83ceada1b Mon Sep 17 00:00:00 2001 From: Anton Midyukov Date: Sun, 10 Apr 2022 13:37:46 +0700 Subject: [PATCH] log.mk, profile.mk: Output errors Step 3 to BUILDLOG and on screen --- lib/log.mk | 2 ++ lib/profile.mk | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/log.mk b/lib/log.mk index 94a51ef9..5a6d647b 100644 --- a/lib/log.mk +++ b/lib/log.mk @@ -25,9 +25,11 @@ ifeq (2,$(DEBUG)) SHELL += -x endif LOG = >>$(BUILDLOG) 2>&1 +LOG_STDERR = 2> >(tee -a $(BUILDLOG) >&2) 1>>$(BUILDLOG) else MAKE += -s LOG = 2>>$(BUILDLOG) >/dev/null +LOG_STDERR = 2> >(tee -a $(BUILDLOG) >&2) 1>/dev/null endif ifeq (,$(filter-out $(DIRECT_TARGETS),$(MAKECMDGOALS))) diff --git a/lib/profile.mk b/lib/profile.mk index 8260371f..4f984773 100644 --- a/lib/profile.mk +++ b/lib/profile.mk @@ -132,7 +132,8 @@ profile/dump-vars: fi $(LOG) # step 3 entry point: copy the needed parts into BUILDDIR +profile/populate: SHELL=/bin/bash profile/populate: profile/finalize profile/dump-vars make-aptbox @for dir in sub.in features.in pkg.in; do \ - $(MAKE) -C $$dir $(LOG); \ + $(MAKE) -C $$dir $(LOG_STDERR); \ done