diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-10 20:49:53 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-10 20:49:53 +0000 |
commit | 87aefc960557c2fb6fdf9ea4c1ac0e7983f68f68 (patch) | |
tree | 263fc56d7d40512aaa09193905008a3f4e3b0018 /debian/extra/kernel | |
parent | Adding upstream version 255.4. (diff) | |
download | systemd-debian/255.4-1.tar.xz systemd-debian/255.4-1.zip |
Adding debian version 255.4-1.debian/255.4-1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rwxr-xr-x | debian/extra/kernel-install.d/55-initrd.install | 26 | ||||
-rwxr-xr-x | debian/extra/kernel/postinst.d/zz-systemd-boot | 11 | ||||
-rwxr-xr-x | debian/extra/kernel/postrm.d/zz-systemd-boot | 11 |
3 files changed, 48 insertions, 0 deletions
diff --git a/debian/extra/kernel-install.d/55-initrd.install b/debian/extra/kernel-install.d/55-initrd.install new file mode 100755 index 0000000..ecbed87 --- /dev/null +++ b/debian/extra/kernel-install.d/55-initrd.install @@ -0,0 +1,26 @@ +#!/bin/sh +set -eu +# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*- +# ex: ts=8 sw=4 sts=4 et filetype=sh + +COMMAND="$1" +KERNEL_VERSION="$2" + +INITRD_SRC="/boot/initrd.img-$KERNEL_VERSION" + +[ "$COMMAND" = add ] || exit 0 + +if [ "$#" -ge 5 ]; then + # Explicit initrd paths were passed, fall through to default 90-loaderentry.install handling; + # we'd be either injecting an unwanted image or, worse, overriding a user-provided one + exit 0 +fi + +if [ -e "$INITRD_SRC" ]; then + [ "$KERNEL_INSTALL_VERBOSE" -gt 0 ] && echo "Installing '$INITRD_SRC'" + ln -fs "$INITRD_SRC" "$KERNEL_INSTALL_STAGING_AREA" +else + echo "$INITRD_SRC does not exist, not installing an initrd" +fi + +exit 0 diff --git a/debian/extra/kernel/postinst.d/zz-systemd-boot b/debian/extra/kernel/postinst.d/zz-systemd-boot new file mode 100755 index 0000000..8901140 --- /dev/null +++ b/debian/extra/kernel/postinst.d/zz-systemd-boot @@ -0,0 +1,11 @@ +#!/bin/sh + +set -e + +test -x /usr/bin/bootctl || exit 0 + +bootctl is-installed --quiet || exit 0 + +echo "Installing kernel version $1 in systemd-boot..." + +kernel-install add "$1" "$2" diff --git a/debian/extra/kernel/postrm.d/zz-systemd-boot b/debian/extra/kernel/postrm.d/zz-systemd-boot new file mode 100755 index 0000000..4db5e51 --- /dev/null +++ b/debian/extra/kernel/postrm.d/zz-systemd-boot @@ -0,0 +1,11 @@ +#!/bin/sh + +set -e + +test -x /usr/bin/bootctl || exit 0 + +bootctl is-installed --quiet || exit 0 + +echo "Removing kernel version $1 from systemd-boot..." + +kernel-install remove "$1" |