mirror of
https://gitlab.com/buildroot.org/buildroot.git
synced 2026-08-01 21:23:51 -09:00
Bump dracut package source to the newest version of the project, dracut-ng, release 110. The original dracut project is now inactive for a long period of time. Dracut community has transitioned to the dracut-ng fork to continue development. The migration ensures regular updates for security and bug fixing, a better support of modern systemd features and kernel requirements. It also allows alignment with major Linux distributions (Fedora, Arch Linux, Gentoo), and other open source projects (Yocto). Changes made : - dracut.mk: change source to dracut-ng 110 - dracut.hash: adapt hash to dracut-ng 110 - dracut.mk: fix unused systemd symbolic links build error - Config.in: adapt fs/cpio/Config.in to mention dracut-ng upgrade - Config.in.host: adapt dracut Config.in.host to mention dracut-ng upgrade - .checkpackageignore: remove 001-dracut.sh-don-t-unset-LD_PRELOAD.patch Patch removals and additions : - Removed 0001-dracut.sh-don-t-unset-LD_PRELOAD.patch: Upstream dracut-ng removed the 'unset LD_PRELOAD' instruction, making this patch obsolete. - Added 0001-fix-functions-prevent-find_binary-from-dropping-last.patch: Dracut-ng introduced a regression on non-merged-usr architectures. This was traced down to a bug in find_binary() where a `while read` loop drops the last PATH element if the string does not end with a colon. This local patch fixes the Bash EOF read behavior. Submitted upstream: https://github.com/dracut-ng/dracut-ng/pull/2416 All dracut related runtime tests, including non-merged-usr, have been locally tested and passed successfully using the reference Buildroot docker container. Signed-off-by: Matéo Pourrier <mateo.pourrier@smile.fr> [Julien: reword commit log title] Signed-off-by: Julien Olivain <ju.o@free.fr>
46 lines
1.5 KiB
Diff
46 lines
1.5 KiB
Diff
From 94c4274e32467235fb580a27ea182169f253ca5f Mon Sep 17 00:00:00 2001
|
|
From: =?UTF-8?q?Mat=C3=A9o=20Pourrier?= <mateo.pourrier@smile.fr>
|
|
Date: Tue, 28 Apr 2026 17:23:23 +0200
|
|
Subject: [PATCH] fix(functions): prevent find_binary from dropping last PATH
|
|
element
|
|
MIME-Version: 1.0
|
|
Content-Type: text/plain; charset=UTF-8
|
|
Content-Transfer-Encoding: 8bit
|
|
|
|
When `read` encounters EOF before the delimiter, it returns a non-zero
|
|
exit status, causing the while loop to terminate immediately. As a result,
|
|
if the PATH string doesn't end with a colon, the very last directory in
|
|
PATH is ignored by find_binary().
|
|
|
|
This caused regressions on split-usr architectures where critical
|
|
binaries reside exclusively in /bin, and /bin happens to be
|
|
appended at the very end of the PATH by dracut.sh.
|
|
|
|
Appending a virtual colon to the Here-String ensures the loop processes
|
|
all directories correctly.
|
|
|
|
Fixes dracut-ng issue #1467 : https://github.com/dracut-ng/dracut-ng/issues/1467
|
|
|
|
Upstream: https://github.com/dracut-ng/dracut-ng/pull/2416
|
|
Signed-off-by: Matéo Pourrier <mateo.pourrier@smile.fr>
|
|
---
|
|
dracut-functions.sh | 2 +-
|
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
|
diff --git a/dracut-functions.sh b/dracut-functions.sh
|
|
index f430a28e..5046f45e 100755
|
|
--- a/dracut-functions.sh
|
|
+++ b/dracut-functions.sh
|
|
@@ -94,7 +94,7 @@ find_binary() {
|
|
printf "%s\n" "${_path}"
|
|
return 0
|
|
fi
|
|
- done <<< "$PATH"
|
|
+ done <<< "${PATH}:"
|
|
|
|
[[ -n ${dracutsysrootdir-} ]] && return 1
|
|
type -P "${1##*/}"
|
|
--
|
|
2.34.1
|
|
|