Commit 73a725f0 authored by Ingo Molnar's avatar Ingo Molnar

tools/perf/build: Standardize the various messages output by parallel make

Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: David Ahern <dsahern@gmail.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Link: http://lkml.kernel.org/n/tip-mky0rtpwxi3ivxsvdjoOEmhr@git.kernel.orgSigned-off-by: default avatarIngo Molnar <mingo@kernel.org>
parent bd69cc28
...@@ -13,13 +13,30 @@ endif ...@@ -13,13 +13,30 @@ endif
export JOBS export JOBS
$(info $(shell printf '# [ perf build: Doing '\''make \033[33m-j'$(JOBS)'\033[m'\'' parallel build. ]\n')) define print_msg
@printf ' BUILD: Doing '\''make \033[33m-j'$(JOBS)'\033[m'\'' parallel build\n'
endef
define make
@$(MAKE) -f Makefile.perf --no-print-directory -j$(JOBS) $@
endef
# #
# Needed if no target specified: # Needed if no target specified:
# #
all: all:
@$(MAKE) -f Makefile.perf --no-print-directory -j$(JOBS) $@ $(print_msg)
$(make)
#
# The clean target is not really parallel, don't print the jobs info:
#
clean:
$(make)
#
# All other targets get passed through:
#
%: %:
@$(MAKE) -f Makefile.perf --no-print-directory -j$(JOBS) $@ $(print_msg)
$(make)
...@@ -179,9 +179,9 @@ endif ...@@ -179,9 +179,9 @@ endif
feature_print = $(eval $(feature_print_code)) feature_print = $(eval $(feature_print_code))
define feature_print_code define feature_print_code
ifeq ($(feature-$(1)), 1) ifeq ($(feature-$(1)), 1)
MSG := $(shell printf '...%30s: [ \033[32mon\033[m ]' $(1)) MSG = $(shell printf '...%30s: [ \033[32mon\033[m ]' $(1))
else else
MSG := $(shell printf '...%30s: [ \033[31mOFF\033[m ]' $(1)) MSG = $(shell printf '...%30s: [ \033[31mOFF\033[m ]' $(1))
endif endif
$(info $(MSG)) $(info $(MSG))
endef endef
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment