public inbox for openembedded-core@lists.openembedded.org
 help / color / mirror / Atom feed
From: Saul Wold <saul.wold@windriver.com>
To: openembedded-core@lists.openembedded.org
Cc: Saul Wold <saul.wold@windriver.com>
Subject: [PATCH v2 1/3] busybox: Exclude .debug from depmod
Date: Thu, 31 Mar 2022 15:21:51 -0700	[thread overview]
Message-ID: <20220331222153.76037-1-saul.wold@windriver.com> (raw)

As with the kmod version of depmod, exclude .debug from being
searched. Since busybox does not use the depmod.d and any 
configuration file option is ignored we just hardcode it.

Signed-off-by: Saul Wold <saul.wold@windriver.com>
---
 ...001-depmod-Ignore-.debug-directories.patch | 32 +++++++++++++++++++
 meta/recipes-core/busybox/busybox_1.35.0.bb   |  1 +
 2 files changed, 33 insertions(+)
 create mode 100644 meta/recipes-core/busybox/busybox/0001-depmod-Ignore-.debug-directories.patch

diff --git a/meta/recipes-core/busybox/busybox/0001-depmod-Ignore-.debug-directories.patch b/meta/recipes-core/busybox/busybox/0001-depmod-Ignore-.debug-directories.patch
new file mode 100644
index 00000000000..354f83a4a5f
--- /dev/null
+++ b/meta/recipes-core/busybox/busybox/0001-depmod-Ignore-.debug-directories.patch
@@ -0,0 +1,32 @@
+From 5f6ed003f10ee0bd4a508d5f59129a29f0920dfc Mon Sep 17 00:00:00 2001
+From: Saul Wold <saul.wold@windriver.com>
+Date: Thu, 31 Mar 2022 11:21:45 -0700
+Subject: [PATCH] depmod: Ignore .debug directories
+
+The .debug/<module>.ko files do not have the correct symbol information
+since it's split away from the actual <module>.ko file. Just ignore it.
+
+Upstream-Status: Pending
+
+Signed-off-by: Saul Wold <saul.wold@windriver.com>
+---
+ modutils/depmod.c | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/modutils/depmod.c b/modutils/depmod.c
+index bb42bbe..aa5a2de 100644
+--- a/modutils/depmod.c
++++ b/modutils/depmod.c
+@@ -43,6 +43,9 @@ static int FAST_FUNC parse_module(struct recursive_state *state,
+ 	/* Arbitrary. Was sb->st_size, but that breaks .gz etc */
+ 	size_t len = (64*1024*1024 - 4096);
+ 
++	if (strstr(fname, ".debug") == NULL)
++		return TRUE;
++
+ 	if (strrstr(fname, ".ko") == NULL)
+ 		return TRUE;
+ 
+-- 
+2.31.1
+
diff --git a/meta/recipes-core/busybox/busybox_1.35.0.bb b/meta/recipes-core/busybox/busybox_1.35.0.bb
index 7ce17170462..ab11f3d89a8 100644
--- a/meta/recipes-core/busybox/busybox_1.35.0.bb
+++ b/meta/recipes-core/busybox/busybox_1.35.0.bb
@@ -1,6 +1,7 @@
 require busybox.inc
 
 SRC_URI = "https://busybox.net/downloads/busybox-${PV}.tar.bz2;name=tarball \
+           file://0001-depmod-Ignore-.debug-directories.patch \
            file://busybox-udhcpc-no_deconfig.patch \
            file://find-touchscreen.sh \
            file://busybox-cron \
-- 
2.31.1



             reply	other threads:[~2022-03-31 22:22 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-31 22:21 Saul Wold [this message]
2022-03-31 22:21 ` [PATCH v2 2/3] kmod: Add an exclude directive to depmod Saul Wold
2022-03-31 22:21 ` [PATCH v2 3/3] depmodwrapper: Use nonarch_base_libdir for depmod.d Saul Wold
2022-04-01 11:11   ` [OE-core] " Richard Purdie
2022-04-01 15:28     ` Saul Wold

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=20220331222153.76037-1-saul.wold@windriver.com \
    --to=saul.wold@windriver.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