Skip to content

Commit 8d79076

Browse files
Jiri Olsaacmel
authored andcommitted
perf tools: Add variable display for VF make output
Adding dump of interesting build directories to the make VF=1 output. $ make VF=1 BUILD: Doing 'make -j4' parallel build Auto-detecting system features: ... dwarf: [ on ] ... glibc: [ on ] ... gtk2: [ on ] ... libaudit: [ on ] ... libbfd: [ on ] ... libelf: [ on ] ... libnuma: [ on ] ... libperl: [ on ] ... libpython: [ on ] ... libslang: [ on ] ... libunwind: [ on ] ... backtrace: [ on ] ... fortify-source: [ on ] ... gtk2-infobar: [ on ] ... libelf-getphdrnum: [ on ] ... libelf-mmap: [ on ] ... libpython-version: [ on ] ... on-exit: [ on ] ... stackprotector-all: [ on ] ... timerfd: [ on ] ... libunwind-debug-frame: [ OFF ] ... bionic: [ OFF ] ... prefix: /home/jolsa ... bindir: /home/jolsa/bin ... libdir: /home/jolsa/lib64 ... sysconfdir: /home/jolsa/etc Adding functions to print variable/text in features display - feature_print_var/feature_print_text (feature_print_text is used in next patches). Signed-off-by: Jiri Olsa <jolsa@redhat.com> Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com> Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Ingo Molnar <mingo@kernel.org> Cc: Jean Pihet <jean.pihet@linaro.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1392825179-5228-3-git-send-email-jolsa@redhat.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
1 parent 0695e57 commit 8d79076

1 file changed

Lines changed: 19 additions & 4 deletions

File tree

‎tools/perf/config/Makefile‎

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -591,16 +591,26 @@ endif
591591
#
592592
# Print the result of the feature test:
593593
#
594-
feature_print = $(eval $(feature_print_code)) $(info $(MSG))
594+
feature_print_status = $(eval $(feature_print_status_code)) $(info $(MSG))
595595

596-
define feature_print_code
596+
define feature_print_status_code
597597
ifeq ($(feature-$(1)), 1)
598598
MSG = $(shell printf '...%30s: [ \033[32mon\033[m ]' $(1))
599599
else
600600
MSG = $(shell printf '...%30s: [ \033[31mOFF\033[m ]' $(1))
601601
endif
602602
endef
603603

604+
feature_print_var = $(eval $(feature_print_var_code)) $(info $(MSG))
605+
define feature_print_var_code
606+
MSG = $(shell printf '...%30s: %s' $(1) $($(1)))
607+
endef
608+
609+
feature_print_text = $(eval $(feature_print_text_code)) $(info $(MSG))
610+
define feature_print_text_code
611+
MSG = $(shell printf '...%30s: %s' $(1) $(2))
612+
endef
613+
604614
PERF_FEATURES := $(foreach feat,$(LIB_FEATURE_TESTS),feature-$(feat)($(feature-$(feat))))
605615
PERF_FEATURES_FILE := $(shell touch $(OUTPUT)PERF-FEATURES; cat $(OUTPUT)PERF-FEATURES)
606616

@@ -633,11 +643,16 @@ endif
633643
ifeq ($(display_lib),1)
634644
$(info )
635645
$(info Auto-detecting system features:)
636-
$(foreach feat,$(LIB_FEATURE_TESTS),$(call feature_print,$(feat),))
646+
$(foreach feat,$(LIB_FEATURE_TESTS),$(call feature_print_status,$(feat),))
637647
endif
638648

639649
ifeq ($(display_vf),1)
640-
$(foreach feat,$(VF_FEATURE_TESTS),$(call feature_print,$(feat),))
650+
$(foreach feat,$(VF_FEATURE_TESTS),$(call feature_print_status,$(feat),))
651+
$(info )
652+
$(call feature_print_var,prefix)
653+
$(call feature_print_var,bindir)
654+
$(call feature_print_var,libdir)
655+
$(call feature_print_var,sysconfdir)
641656
endif
642657

643658
ifeq ($(display_lib),1)

0 commit comments

Comments
 (0)