Skip to content

Commit 4781179

Browse files
committed
selftests: kvm: remove meaningless assignments in Makefiles
$(shell ...) expands to the output of the command. It expands to the empty string when the command does not print anything to stdout. Hence, $(shell mkdir ...) is sufficient and does not need any variable assignment in front of it. Commit c2bd08b ("treewide: remove meaningless assignments in Makefiles", 2024-02-23) did this to all of tools/ but ignored in-flight changes to tools/testing/selftests/kvm/Makefile, so reapply the change. Cc: Masahiro Yamada <masahiroy@kernel.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
1 parent 17193ce commit 4781179

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tools/testing/selftests/kvm/Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,7 @@ TEST_DEP_FILES += $(patsubst %.o, %.d, $(LIBKVM_OBJS))
277277
TEST_DEP_FILES += $(patsubst %.o, %.d, $(SPLIT_TEST_GEN_OBJ))
278278
-include $(TEST_DEP_FILES)
279279

280-
x := $(shell mkdir -p $(sort $(OUTPUT)/$(ARCH_DIR) $(dir $(LIBKVM_C_OBJ) $(LIBKVM_S_OBJ))))
280+
$(shell mkdir -p $(sort $(OUTPUT)/$(ARCH_DIR) $(dir $(LIBKVM_C_OBJ) $(LIBKVM_S_OBJ))))
281281

282282
$(filter-out $(SPLIT_TEST_GEN_PROGS), $(TEST_GEN_PROGS)) \
283283
$(TEST_GEN_PROGS_EXTENDED): %: %.o
@@ -309,7 +309,7 @@ $(LIBKVM_S_OBJ): $(OUTPUT)/%.o: %.S $(GEN_HDRS)
309309
$(LIBKVM_STRING_OBJ): $(OUTPUT)/%.o: %.c
310310
$(CC) $(CFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -c -ffreestanding $< -o $@
311311

312-
x := $(shell mkdir -p $(sort $(dir $(TEST_GEN_PROGS))))
312+
$(shell mkdir -p $(sort $(dir $(TEST_GEN_PROGS))))
313313
$(SPLIT_TEST_GEN_OBJ): $(GEN_HDRS)
314314
$(TEST_GEN_PROGS): $(LIBKVM_OBJS)
315315
$(TEST_GEN_PROGS_EXTENDED): $(LIBKVM_OBJS)

0 commit comments

Comments
 (0)