Skip to content

Commit 965b9fe

Browse files
anakryikoAlexei Starovoitov
authored andcommitted
selftests/bpf: Further clean up Makefile output
Further clean up Makefile output: - hide "entering directory" messages; - silvence sub-Make command echoing; - succinct MKDIR messages. Also remove few test binaries that are not produced anymore from .gitignore. Signed-off-by: Andrii Nakryiko <[email protected]> Signed-off-by: Alexei Starovoitov <[email protected]> Link: https://lore.kernel.org/bpf/[email protected]
1 parent 6910d7d commit 965b9fe

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

tools/testing/selftests/bpf/.gitignore

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,9 @@ get_cgroup_id_user
2222
test_skb_cgroup_id_user
2323
test_socket_cookie
2424
test_cgroup_storage
25-
test_select_reuseport
2625
test_flow_dissector
2726
flow_dissector_load
2827
test_netcnt
29-
test_section_names
3028
test_tcpnotify_user
3129
test_libbpf
3230
test_tcp_check_syncookie_user

tools/testing/selftests/bpf/Makefile

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -83,9 +83,12 @@ TEST_CUSTOM_PROGS = urandom_read
8383
# $3 - target (assumed to be file); only file name will be emitted;
8484
# $4 - optional extra arg, emitted as-is, if provided.
8585
ifeq ($(V),1)
86+
Q =
8687
msg =
8788
else
89+
Q = @
8890
msg = @$(info $(1)$(if $(2), [$(2)]) $(notdir $(3)))$(if $(4), $(4))
91+
MAKEFLAGS += --no-print-directory
8992
endif
9093

9194
# override lib.mk's default rules
@@ -147,14 +150,14 @@ DEFAULT_BPFTOOL := $(OUTPUT)/tools/usr/local/sbin/bpftool
147150
BPFTOOL ?= $(DEFAULT_BPFTOOL)
148151

149152
$(DEFAULT_BPFTOOL): force
150-
$(MAKE) -C $(BPFTOOLDIR) DESTDIR=$(OUTPUT)/tools install
153+
$(Q)$(MAKE) -C $(BPFTOOLDIR) DESTDIR=$(OUTPUT)/tools install
151154

152155
$(BPFOBJ): force
153-
$(MAKE) -C $(BPFDIR) OUTPUT=$(OUTPUT)/
156+
$(Q)$(MAKE) -C $(BPFDIR) OUTPUT=$(OUTPUT)/
154157

155158
BPF_HELPERS := $(OUTPUT)/bpf_helper_defs.h $(wildcard $(BPFDIR)/bpf_*.h)
156159
$(OUTPUT)/bpf_helper_defs.h: $(BPFOBJ)
157-
$(MAKE) -C $(BPFDIR) OUTPUT=$(OUTPUT)/ $(OUTPUT)/bpf_helper_defs.h
160+
$(Q)$(MAKE) -C $(BPFDIR) OUTPUT=$(OUTPUT)/ $(OUTPUT)/bpf_helper_defs.h
158161

159162
# Get Clang's default includes on this system, as opposed to those seen by
160163
# '-target bpf'. This fixes "missing" files on some architectures/distros,
@@ -253,6 +256,7 @@ define DEFINE_TEST_RUNNER_RULES
253256
ifeq ($($(TRUNNER_OUTPUT)-dir),)
254257
$(TRUNNER_OUTPUT)-dir := y
255258
$(TRUNNER_OUTPUT):
259+
$$(call msg, MKDIR,,$$@)
256260
mkdir -p $$@
257261
endif
258262

0 commit comments

Comments
 (0)