Backport patches to unbreak systemd v255

This commit is contained in:
Zbigniew Jędrzejewski-Szmek 2023-11-08 14:43:42 +01:00
parent 81c46b8ffb
commit 6fb02070d3
4 changed files with 96 additions and 1 deletions

View File

@ -0,0 +1,34 @@
From 805728cabf81ddef6a550b95d08f1f6e00e0cf8b Mon Sep 17 00:00:00 2001
From: Antonio Alvarez Feijoo <antonio.feijoo@suse.com>
Date: Tue, 26 Sep 2023 08:12:23 +0200
Subject: [PATCH] fix(systemd-pcrphase): rename systemd-pcrphase binary to
systemd-pcrextend
The `systemd-pcrphase` binary has been renamed to `systemd-pcrextend` since
https://github.com/systemd/systemd/commit/32295fa0
---
modules.d/01systemd-pcrphase/module-setup.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/modules.d/01systemd-pcrphase/module-setup.sh b/modules.d/01systemd-pcrphase/module-setup.sh
index 3dbb4974ef..b9817e6405 100755
--- a/modules.d/01systemd-pcrphase/module-setup.sh
+++ b/modules.d/01systemd-pcrphase/module-setup.sh
@@ -6,7 +6,7 @@
check() {
# If the binary(s) requirements are not fulfilled the module can't be installed.
- require_binaries "$systemdutildir"/systemd-pcrphase || return 1
+ require_binaries "$systemdutildir"/systemd-pcrextend || return 1
# Return 255 to only include the module, if another module requires it.
return 255
@@ -27,7 +27,7 @@ depends() {
install() {
inst_multiple -o \
- "$systemdutildir"/systemd-pcrphase \
+ "$systemdutildir"/systemd-pcrextend \
"$systemdsystemunitdir"/systemd-pcrphase.service \
"$systemdsystemunitdir/systemd-pcrphase.service.d/*.conf" \
"$systemdsystemunitdir"/systemd-pcrphase-sysinit.service \

26
2527.patch Normal file
View File

@ -0,0 +1,26 @@
From a2fe89116db4b286fbf515f26bd1773b5e6ee8ad Mon Sep 17 00:00:00 2001
From: Antonio Alvarez Feijoo <antonio.feijoo@suse.com>
Date: Tue, 26 Sep 2023 09:43:37 +0200
Subject: [PATCH] fix(resume): add new systemd-hibernate-resume.service
Since https://github.com/systemd/systemd/commit/a628d933, the generator only
does the initial validation of the system info and then enables the new
`systemd-hibernate-resume.service`.
Fixes #2513
---
modules.d/95resume/module-setup.sh | 1 +
1 file changed, 1 insertion(+)
diff --git a/modules.d/95resume/module-setup.sh b/modules.d/95resume/module-setup.sh
index d255103366..9204f9cb73 100755
--- a/modules.d/95resume/module-setup.sh
+++ b/modules.d/95resume/module-setup.sh
@@ -44,6 +44,7 @@ install() {
if dracut_module_included "systemd" && [[ -x $dracutsysrootdir$systemdutildir/systemd-hibernate-resume ]]; then
inst_multiple -o \
"$systemdutildir"/system-generators/systemd-hibernate-resume-generator \
+ "$systemdsystemunitdir"/systemd-hibernate-resume.service \
"$systemdsystemunitdir"/systemd-hibernate-resume@.service \
"$systemdutildir"/systemd-hibernate-resume
return 0

View File

@ -0,0 +1,26 @@
From bee1c4824a8cd47ce6c01892a548bdc07b1fa678 Mon Sep 17 00:00:00 2001
From: Frantisek Sumsal <frantisek@sumsal.cz>
Date: Sat, 14 Oct 2023 23:45:57 +0200
Subject: [PATCH] feat(systemd): install systemd-executor
In [0] systemd gained a new binary - systemd-executor - that's used to
spawn processes forked off systemd. Let's copy it into the initrd if
it's available.
[0] https://github.com/systemd/systemd/pull/27890
---
modules.d/00systemd/module-setup.sh | 1 +
1 file changed, 1 insertion(+)
diff --git a/modules.d/00systemd/module-setup.sh b/modules.d/00systemd/module-setup.sh
index 554c25a08..9a13a1dbb 100755
--- a/modules.d/00systemd/module-setup.sh
+++ b/modules.d/00systemd/module-setup.sh
@@ -34,6 +34,7 @@ install() {
"$systemdutildir"/systemd \
"$systemdutildir"/systemd-coredump \
"$systemdutildir"/systemd-cgroups-agent \
+ "$systemdutildir"/systemd-executor \
"$systemdutildir"/systemd-shutdown \
"$systemdutildir"/systemd-reply-password \
"$systemdutildir"/systemd-fsck \

View File

@ -7,7 +7,7 @@
%global __requires_exclude pkg-config
# rpmdev-bumpspec and releng automation compatible variable
%global baserelease 15
%global baserelease 16
Name: dracut
Version: 059
@ -83,6 +83,12 @@ Patch12: 0001-fix-make-iso-scan-trigger-udev-events.patch
# https://github.com/dracutdevs/dracut/pull/2545
Patch13: 0001-fix-wait-12-hours-before-halt-on-media-check-fail.patch
# Unbreak new systemd
Patch14: https://github.com/dracutdevs/dracut/commit/bee1c4824a8cd47ce6c01892a548bdc07b1fa678.patch
# https://github.com/dracutdevs/dracut/pull/2526.patch rebased
Patch15: 0001-fix-systemd-pcrphase-rename-systemd-pcrphase-binary-.patch
Patch16: https://github.com/dracutdevs/dracut/pull/2527.patch
BuildRequires: bash
BuildRequires: git-core
BuildRequires: pkgconfig(libkmod) >= 23
@ -483,6 +489,9 @@ echo 'dracut_rescue_image="yes"' > $RPM_BUILD_ROOT%{dracutlibdir}/dracut.conf.d/
%{_prefix}/lib/kernel/install.d/51-dracut-rescue.install
%changelog
* Wed Nov 8 2023 Zbigniew Jedrzejewski-Szmek <zbyszek@in.waw.pl> - 059-16
- Backport patches to fix compatibility with systemd 255
* Sat Oct 28 2023 Adam Williamson <awilliam@redhat.com> - 059-15
- Backport PR #2545 to fix media check failure visibility