Skip to contentSkip to conversation

selftests/bpf: Include runner extras for install target

PATCH Superseded Björn Töpel 1 participant 2 messages Jan 25, 2024

Subsystems (5)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 selftests/bpf: Include runner extras for install target

From: Björn Töpel <[email protected]>

When using the "install" or targets depending on install, e.g. "gen_tar", the "runner extras" weren't included for the BPF machine flavors.

Make sure the necessary helper scripts/tools are added to corresponding BPF machine flavor.

---
tools/testing/selftests/bpf/Makefile | 10 ++++++++++

 1 file changed, 10 insertions(+)
tools/testing/selftests/bpf/Makefile +10 -0
index fd15017ed3b1..a5e63ef78bf1 100644
@@ -747,5 +747,15 @@ override define INSTALL_RULE
 	@for DIR in $(TEST_INST_SUBDIRS); do		  \
 		mkdir -p $(INSTALL_PATH)/$$DIR;   \
 		rsync -a $(OUTPUT)/$$DIR/*.bpf.o $(INSTALL_PATH)/$$DIR;\
+		rsync -a --copy-unsafe-links \
+			$(OUTPUT)/$$DIR/bpf_testmod.ko \
+			$(OUTPUT)/$$DIR/bpftool \
+			$(OUTPUT)/$$DIR/ima_setup.sh \
+			$(OUTPUT)/$$DIR/liburandom_read.so \
+			$(OUTPUT)/$$DIR/sign-file \
+			$(OUTPUT)/$$DIR/uprobe_multi \
+			$(OUTPUT)/$$DIR/urandom_read \
+			$(OUTPUT)/$$DIR/verify_sig_setup.sh \
+			$(OUTPUT)/$$DIR/xdp_synproxy $(INSTALL_PATH)/$$DIR;\
 	done
 endef

base-commit: c8632acf193beac64bbdaebef013368c480bf74f

Signature · 1 line
2.40.1
#1 lore raw
Quoted 22 lines · Björn Töpel

From: Björn Töpel <[email protected]>

When using the "install" or targets depending on install, e.g. "gen_tar", the "runner extras" weren't included for the BPF machine flavors.

Make sure the necessary helper scripts/tools are added to corresponding BPF machine flavor.

---
tools/testing/selftests/bpf/Makefile | 10 ++++++++++

 1 file changed, 10 insertions(+)
tools/testing/selftests/bpf/Makefile +0 -0
index fd15017ed3b1..a5e63ef78bf1 100644
@@ -747,5 +747,15 @@ override define INSTALL_RULE
 	@for DIR in $(TEST_INST_SUBDIRS); do		  \
 		mkdir -p $(INSTALL_PATH)/$$DIR;   \
 		rsync -a $(OUTPUT)/$$DIR/*.bpf.o $(INSTALL_PATH)/$$DIR;\

tools/testing/selftests/bpf/Makefile override define INSTALL_RULE · line 759

Quoted 10 lines
tools/testing/selftests/bpf/Makefile +10 -0
+		rsync -a --copy-unsafe-links \
+			$(OUTPUT)/$$DIR/bpf_testmod.ko \
+			$(OUTPUT)/$$DIR/bpftool \
+			$(OUTPUT)/$$DIR/ima_setup.sh \
+			$(OUTPUT)/$$DIR/liburandom_read.so \
+			$(OUTPUT)/$$DIR/sign-file \
+			$(OUTPUT)/$$DIR/uprobe_multi \
+			$(OUTPUT)/$$DIR/urandom_read \
+			$(OUTPUT)/$$DIR/verify_sig_setup.sh \
+			$(OUTPUT)/$$DIR/xdp_synproxy $(INSTALL_PATH)/$$DIR;\

Nevermind this patch. The btf_dump_test_case*.c files are missing. I'll spin a v2 (and also try to avoid the name duplication from TRUNNER_EXTRA_FILES).

Björn