From: Vincent Mailhol <mailhol@kernel.org>
To: Nathan Chancellor <nathan@kernel.org>, Nicolas Schier <nsc@kernel.org>
Cc: linux-kernel@vger.kernel.org, linux-kbuild@vger.kernel.org,
Vincent Mailhol <mailhol@kernel.org>
Subject: [PATCH 2/3] kbuild: move preparation checks out of single-build
Date: Wed, 11 Nov 2026 14:41:04 +0100 [thread overview]
Message-ID: <20261111-reduce-single-build-dependencies-v1-2-7196ca986a85@kernel.org> (raw)
In-Reply-To: <20261111-reduce-single-build-dependencies-v1-0-7196ca986a85@kernel.org>
The missing-syscalls check and the atomic-checks are currently set as
preparation dependencies. However, these are not needed to compile, for
example, a single object.
Add a new prepare_checks target to group those checks and call it
conditionally only if we are not doing a single-build so that the
prepare target does not trigger that dependency anymore.
Signed-off-by: Vincent Mailhol <mailhol@kernel.org>
---
Kbuild | 7 +++++--
Makefile | 2 +-
2 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/Kbuild b/Kbuild
index 5a65be2d51b0..5151e32985c6 100644
--- a/Kbuild
+++ b/Kbuild
@@ -86,8 +86,11 @@ $(atomic-checks): $(obj)/.checked-%: include/linux/atomic/% FORCE
# A phony target that depends on all the preparation targets
-PHONY += prepare
-prepare: $(rq-offsets-file) missing-syscalls $(atomic-checks)
+PHONY += prepare prepare_checks
+prepare: $(rq-offsets-file)
+ @:
+
+prepare_checks: missing-syscalls $(atomic-checks)
@:
# Ordinary directory descending
diff --git a/Makefile b/Makefile
index f895752d4b05..2c1289a44c56 100644
--- a/Makefile
+++ b/Makefile
@@ -1413,8 +1413,8 @@ archprepare: outputmakefile archheaders archscripts scripts include/config/kerne
include/generated/rustc_cfg remove-stale-files
prepare0: archprepare
+ $(Q)$(MAKE) $(build)=. prepare $(if $(single-build),,prepare_checks)
$(Q)$(MAKE) $(build)=scripts/mod
- $(Q)$(MAKE) $(build)=. prepare
# All the preparing..
prepare: prepare0
--
2.56.1
next prev parent reply other threads:[~2026-11-11 13:41 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-11 13:41 [PATCH 0/3] kbuild: reduce single-build dependencies Vincent Mailhol
2026-11-11 13:41 ` [PATCH 1/3] kbuild: make rq-offsets-file an explicit preparation dependency Vincent Mailhol
2026-11-11 13:41 ` Vincent Mailhol [this message]
2026-11-11 13:41 ` [PATCH 3/3] kbuild: move scripts/mod target out of single-build Vincent Mailhol
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=20261111-reduce-single-build-dependencies-v1-2-7196ca986a85@kernel.org \
--to=mailhol@kernel.org \
--cc=linux-kbuild@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=nathan@kernel.org \
--cc=nsc@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®