From: Baoquan He <bhe@redhat.com>
To: Moon Hee Lee <moonhee.lee.ca@gmail.com>
Cc: khan@linuxfoundation.org, kexec@lists.infradead.org,
dwmw@amazon.co.uk, mingo@kernel.org,
linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-kernel-mentees@lists.linux.dev, shuah@kernel.org,
Shuah Khan <skhan@linuxfoundation.org>
Subject: Re: [PATCH v2] selftests/kexec: fix test_kexec_jump build
Date: Thu, 3 Jul 2025 14:44:36 +0800 [thread overview]
Message-ID: <aGYm1BARlztCoCLT@MiWiFi-R3L-srv> (raw)
In-Reply-To: <20250702171704.22559-2-moonhee.lee.ca@gmail.com>
On 07/02/25 at 10:17am, Moon Hee Lee wrote:
> 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.
I can reproduce this, and this patch fixes it. Thanks.
Acked-by: Baoquan He <bhe@redhat.com>
>
> 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.
>
> Acked-by: Shuah Khan <skhan@linuxfoundation.org>
> Signed-off-by: Moon Hee Lee <moonhee.lee.ca@gmail.com>
> ---
> Changes in v2:
> - Dropped the .gitignore addition, as it is already handled in [1]
>
> [1] https://lore.kernel.org/r/20250623232549.3263273-1-dyudaken@gmail.com
>
>
> tools/testing/selftests/kexec/Makefile | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tools/testing/selftests/kexec/Makefile b/tools/testing/selftests/kexec/Makefile
> index e3000ccb9a5d..874cfdd3b75b 100644
> --- a/tools/testing/selftests/kexec/Makefile
> +++ b/tools/testing/selftests/kexec/Makefile
> @@ -12,7 +12,7 @@ include ../../../scripts/Makefile.arch
>
> ifeq ($(IS_64_BIT)$(ARCH_PROCESSED),1x86)
> TEST_PROGS += test_kexec_jump.sh
> -test_kexec_jump.sh: $(OUTPUT)/test_kexec_jump
> +TEST_GEN_PROGS := test_kexec_jump
> endif
>
> include ../lib.mk
> --
> 2.43.0
>
>
next prev parent reply other threads:[~2025-07-03 6:52 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-02 17:17 [PATCH v2] selftests/kexec: fix test_kexec_jump build Moon Hee Lee
2025-07-02 17:37 ` Moonhee Lee
2025-07-03 6:44 ` Baoquan He [this message]
2025-07-08 7:18 ` Woodhouse, David
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aGYm1BARlztCoCLT@MiWiFi-R3L-srv \
--to=bhe@redhat.com \
--cc=dwmw@amazon.co.uk \
--cc=kexec@lists.infradead.org \
--cc=khan@linuxfoundation.org \
--cc=linux-kernel-mentees@lists.linux.dev \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=moonhee.lee.ca@gmail.com \
--cc=shuah@kernel.org \
--cc=skhan@linuxfoundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.