Skip to content

Commit 19177bc

Browse files
committed
tools build: Allow deferring printing the results of feature detection
By setting FEATURE_DISPLAY_DEFERRED=1 a tool may ask for the printout of the detected features in tools/build/Makefile.feature to be done later adter extra feature checks are done that are tool specific. The perf tool will do it via its tools/perf/Makefile.config, as it performs such extra feature checks. Acked-by: Jiri Olsa <[email protected]> Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
1 parent fbed59f commit 19177bc

File tree

1 file changed

+17
-10
lines changed

1 file changed

+17
-10
lines changed

tools/build/Makefile.feature

Lines changed: 17 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -240,17 +240,24 @@ ifeq ($(VF),1)
240240
feature_verbose := 1
241241
endif
242242

243-
ifeq ($(feature_display),1)
244-
$(info )
245-
$(info Auto-detecting system features:)
246-
$(foreach feat,$(FEATURE_DISPLAY),$(call feature_print_status,$(feat),))
247-
ifneq ($(feature_verbose),1)
243+
feature_display_entries = $(eval $(feature_display_entries_code))
244+
define feature_display_entries_code
245+
ifeq ($(feature_display),1)
248246
$(info )
247+
$(info Auto-detecting system features:)
248+
$(foreach feat,$(FEATURE_DISPLAY),$(call feature_print_status,$(feat),))
249+
ifneq ($(feature_verbose),1)
250+
$(info )
251+
endif
249252
endif
250-
endif
251253

252-
ifeq ($(feature_verbose),1)
253-
TMP := $(filter-out $(FEATURE_DISPLAY),$(FEATURE_TESTS))
254-
$(foreach feat,$(TMP),$(call feature_print_status,$(feat),))
255-
$(info )
254+
ifeq ($(feature_verbose),1)
255+
TMP := $(filter-out $(FEATURE_DISPLAY),$(FEATURE_TESTS))
256+
$(foreach feat,$(TMP),$(call feature_print_status,$(feat),))
257+
$(info )
258+
endif
259+
endef
260+
261+
ifeq ($(FEATURE_DISPLAY_DEFERRED),)
262+
$(call feature_display_entries)
256263
endif

0 commit comments

Comments
 (0)