Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

tools: Unify top-level quiet infrastructure

Commit f2868b1a66d4f40f ("perf tools: Expose quiet/verbose variables in
Makefile.perf") moved the quiet infrastructure out of
tools/build/Makefile.build and into the top-level Makefile.perf file so
that the quiet infrastructure could be used throughout perf and not just
in Makefile.build.

Extract out the quiet infrastructure into Makefile.include so that it
can be leveraged outside of perf.

Fixes: f2868b1a66d4f40f ("perf tools: Expose quiet/verbose variables in Makefile.perf")
Reviewed-by: Jiri Olsa <jolsa@kernel.org>
Signed-off-by: Charlie Jenkins <charlie@rivosinc.com>
Acked-by: Andrii Nakryiko <andrii@kernel.org>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Alexei Starovoitov <ast@kernel.org>
Cc: Benjamin Tissoires <bentiss@kernel.org>
Cc: Daniel Borkmann <daniel@iogearbox.net>
Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
Cc: Eduard Zingerman <eddyz87@gmail.com>
Cc: Hao Luo <haoluo@google.com>
Cc: Ian Rogers <irogers@google.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Jiri Kosina <jikos@kernel.org>
Cc: John Fastabend <john.fastabend@gmail.com>
Cc: Josh Poimboeuf <jpoimboe@kernel.org>
Cc: KP Singh <kpsingh@kernel.org>
Cc: Lukasz Luba <lukasz.luba@arm.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Martin KaFai Lau <martin.lau@linux.dev>
Cc: Mykola Lysenko <mykolal@fb.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Quentin Monnet <qmo@kernel.org>
Cc: Rafael J. Wysocki <rafael@kernel.org>
Cc: Shuah Khan <shuah@kernel.org>
Cc: Song Liu <song@kernel.org>
Cc: Stanislav Fomichev <sdf@google.com>
Cc: Steven Rostedt (VMware) <rostedt@goodmis.org>
Cc: Yonghong Song <yonghong.song@linux.dev>
Cc: Zhang Rui <rui.zhang@intel.com>
Link: https://lore.kernel.org/r/20250213-quiet_tools-v3-1-07de4482a581@rivosinc.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>

authored by

Charlie Jenkins and committed by
Arnaldo Carvalho de Melo
293f324c 9fae5884

+31 -48
+1 -7
tools/build/Makefile
··· 17 17 18 18 export HOSTCC HOSTLD HOSTAR 19 19 20 - ifeq ($(V),1) 21 - Q = 22 - else 23 - Q = @ 24 - endif 25 - 26 - export Q srctree CC LD 20 + export srctree CC LD 27 21 28 22 MAKEFLAGS := --no-print-directory 29 23 build := -f $(srctree)/tools/build/Makefile.build dir=. obj
-41
tools/perf/Makefile.perf
··· 161 161 SOURCE := $(shell ln -sf $(srctree)/tools/perf $(OUTPUT)/source) 162 162 endif 163 163 164 - # Beautify output 165 - # --------------------------------------------------------------------------- 166 - # 167 - # Most of build commands in Kbuild start with "cmd_". You can optionally define 168 - # "quiet_cmd_*". If defined, the short log is printed. Otherwise, no log from 169 - # that command is printed by default. 170 - # 171 - # e.g.) 172 - # quiet_cmd_depmod = DEPMOD $(MODLIB) 173 - # cmd_depmod = $(srctree)/scripts/depmod.sh $(DEPMOD) $(KERNELRELEASE) 174 - # 175 - # A simple variant is to prefix commands with $(Q) - that's useful 176 - # for commands that shall be hidden in non-verbose mode. 177 - # 178 - # $(Q)$(MAKE) $(build)=scripts/basic 179 - # 180 - # To put more focus on warnings, be less verbose as default 181 - # Use 'make V=1' to see the full commands 182 - 183 - ifeq ($(V),1) 184 - quiet = 185 - Q = 186 - else 187 - quiet=quiet_ 188 - Q=@ 189 - endif 190 - 191 - # If the user is running make -s (silent mode), suppress echoing of commands 192 - # make-4.0 (and later) keep single letter options in the 1st word of MAKEFLAGS. 193 - ifeq ($(filter 3.%,$(MAKE_VERSION)),) 194 - short-opts := $(firstword -$(MAKEFLAGS)) 195 - else 196 - short-opts := $(filter-out --%,$(MAKEFLAGS)) 197 - endif 198 - 199 - ifneq ($(findstring s,$(short-opts)),) 200 - quiet=silent_ 201 - endif 202 - 203 - export quiet Q 204 - 205 164 # Do not use make's built-in rules 206 165 # (this improves performance and avoids hard-to-debug behaviour); 207 166 MAKEFLAGS += -r
+30
tools/scripts/Makefile.include
··· 136 136 NO_SUBDIR = : 137 137 endif 138 138 139 + # Beautify output 140 + # --------------------------------------------------------------------------- 141 + # 142 + # Most of build commands in Kbuild start with "cmd_". You can optionally define 143 + # "quiet_cmd_*". If defined, the short log is printed. Otherwise, no log from 144 + # that command is printed by default. 145 + # 146 + # e.g.) 147 + # quiet_cmd_depmod = DEPMOD $(MODLIB) 148 + # cmd_depmod = $(srctree)/scripts/depmod.sh $(DEPMOD) $(KERNELRELEASE) 149 + # 150 + # A simple variant is to prefix commands with $(Q) - that's useful 151 + # for commands that shall be hidden in non-verbose mode. 152 + # 153 + # $(Q)$(MAKE) $(build)=scripts/basic 154 + # 155 + # To put more focus on warnings, be less verbose as default 156 + # Use 'make V=1' to see the full commands 157 + 158 + ifeq ($(V),1) 159 + quiet = 160 + Q = 161 + else 162 + quiet = quiet_ 163 + Q = @ 164 + endif 165 + 139 166 # If the user is running make -s (silent mode), suppress echoing of commands 140 167 # make-4.0 (and later) keep single letter options in the 1st word of MAKEFLAGS. 141 168 ifeq ($(filter 3.%,$(MAKE_VERSION)),) ··· 173 146 174 147 ifneq ($(findstring s,$(short-opts)),) 175 148 silent=1 149 + quiet=silent_ 176 150 endif 151 + 152 + export quiet Q 177 153 178 154 # 179 155 # Define a callable command for descending to a new directory