From: mark.yang@lge.com
To: openembedded-core@lists.openembedded.org
Cc: "mark.yang" <mark.yang@lge.com>
Subject: [PATCH v2 2/3] module.bbclass/make-mod-scripts: inhibit default dependencies
Date: Tue, 14 Jul 2026 22:26:41 +0900 [thread overview]
Message-ID: <20260714132642.2225115-3-mark.yang@lge.com> (raw)
In-Reply-To: <20260714132642.2225115-1-mark.yang@lge.com>
From: "mark.yang" <mark.yang@lge.com>
Modules and make-mod-scripts build against the shared kernel build
tree with the kernel toolchain, so the default virtual/libc and
virtual/compilerlibs dependencies are unused. Inhibit them and add
the cross toolchain explicitly, as kernel.bbclass does, which also
keeps compiler-rt and libcxx out of module builds with clang.
Signed-off-by: mark.yang <mark.yang@lge.com>
---
v2: split out of the KERNEL_TOOLCHAIN patch
meta/classes-recipe/module.bbclass | 3 +++
meta/recipes-kernel/make-mod-scripts/make-mod-scripts_1.0.bb | 3 +++
2 files changed, 6 insertions(+)
diff --git a/meta/classes-recipe/module.bbclass b/meta/classes-recipe/module.bbclass
index 6b2c09f441..ce5898125b 100644
--- a/meta/classes-recipe/module.bbclass
+++ b/meta/classes-recipe/module.bbclass
@@ -6,6 +6,9 @@
inherit module-base kernel-module-split pkgconfig
+INHIBIT_DEFAULT_DEPS = "1"
+DEPENDS += "virtual/cross-cc virtual/cross-binutils"
+
EXTRA_OEMAKE += "KERNEL_SRC=${STAGING_KERNEL_DIR}"
MODULES_INSTALL_TARGET ?= "modules_install"
diff --git a/meta/recipes-kernel/make-mod-scripts/make-mod-scripts_1.0.bb b/meta/recipes-kernel/make-mod-scripts/make-mod-scripts_1.0.bb
index 4b0630313f..338a50de91 100644
--- a/meta/recipes-kernel/make-mod-scripts/make-mod-scripts_1.0.bb
+++ b/meta/recipes-kernel/make-mod-scripts/make-mod-scripts_1.0.bb
@@ -18,6 +18,9 @@ DEV_PKG_DEPENDENCY = ""
DEPENDS += "bc-native bison-native"
DEPENDS += "gmp-native"
+INHIBIT_DEFAULT_DEPS = "1"
+DEPENDS += "virtual/cross-cc virtual/cross-binutils"
+
EXTRA_OEMAKE = " HOSTCC="${BUILD_CC}" HOSTCFLAGS="${BUILD_CFLAGS}" HOSTLDFLAGS="${BUILD_LDFLAGS}" HOSTCPP="${BUILD_CPP}""
EXTRA_OEMAKE += " HOSTCXX="${BUILD_CXX} ${BUILD_CXXFLAGS} ${BUILD_LDFLAGS}" CROSS_COMPILE=${TARGET_PREFIX}"
next prev parent reply other threads:[~2026-07-14 13:26 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-14 13:26 [PATCH v2 0/3] kernel: make the kernel toolchain switchable to clang mark.yang
2026-07-14 13:26 ` [PATCH v2 1/3] kernel-arch: fall back to GNU ld unless ld-is-lld is in DISTRO_FEATURES mark.yang
2026-07-14 13:26 ` mark.yang [this message]
2026-07-15 11:34 ` [OE-core] [PATCH v2 2/3] module.bbclass/make-mod-scripts: inhibit default dependencies Mathieu Dubois-Briand
2026-07-15 13:48 ` Mathieu Dubois-Briand
2026-07-16 6:40 ` mark.yang
2026-07-14 13:26 ` [PATCH v2 3/3] kernel-arch: add KERNEL_TOOLCHAIN to switch the whole kernel toolchain mark.yang
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=20260714132642.2225115-3-mark.yang@lge.com \
--to=mark.yang@lge.com \
--cc=openembedded-core@lists.openembedded.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