Skip to content

Commit 661e9cd

Browse files
moonheeleeshuahkh
authored andcommitted
selftests/kexec: fix test_kexec_jump build
The test_kexec_jump program builds correctly when invoked from the top-level selftests/Makefile, which explicitly sets the OUTPUT variable. However, building directly in tools/testing/selftests/kexec fails with: make: *** No rule to make target '/test_kexec_jump', needed by 'test_kexec_jump.sh'. Stop. This failure occurs because the Makefile rule relies on $(OUTPUT), which is undefined in direct builds. Fix this by listing test_kexec_jump in TEST_GEN_PROGS, the standard way to declare generated test binaries in the kselftest framework. This ensures the binary is built regardless of invocation context and properly removed by make clean. Link: https://lore.kernel.org/r/20250702171704.22559-2-moonhee.lee.ca@gmail.com Acked-by: Shuah Khan <skhan@linuxfoundation.org> Signed-off-by: Moon Hee Lee <moonhee.lee.ca@gmail.com> Acked-by: Baoquan He <bhe@redhat.com> Acked-by: David Woodhouse <dwmw@amazon.co.uk> Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
1 parent 07b7c2b commit 661e9cd

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

tools/testing/selftests/kexec/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ include ../../../scripts/Makefile.arch
1212

1313
ifeq ($(IS_64_BIT)$(ARCH_PROCESSED),1x86)
1414
TEST_PROGS += test_kexec_jump.sh
15-
test_kexec_jump.sh: $(OUTPUT)/test_kexec_jump
15+
TEST_GEN_PROGS := test_kexec_jump
1616
endif
1717

1818
include ../lib.mk

0 commit comments

Comments
 (0)