mirror of
https://git.proxmox.com/git/efi-boot-shim
synced 2025-10-04 11:58:25 +00:00
Fix up the template maintainer scripts
if we're not running on an EFI system then exit cleanly
This commit is contained in:
parent
29f231fd04
commit
fca6905653
7
debian/changelog
vendored
7
debian/changelog
vendored
@ -1,3 +1,10 @@
|
||||
shim (15.4-4) unstable; urgency=medium
|
||||
|
||||
* Fix up those maintainer scripts - if we're not running on an EFI
|
||||
system then exit cleanly.
|
||||
|
||||
-- Steve McIntyre <93sam@debian.org> Tue, 04 May 2021 17:53:21 +0100
|
||||
|
||||
shim (15.4-3) unstable; urgency=medium
|
||||
|
||||
* Add maintainer scripts to the template packages to manage
|
||||
|
6
debian/signing-template/@final_pkg_name@.postinst.in
vendored
Normal file → Executable file
6
debian/signing-template/@final_pkg_name@.postinst.in
vendored
Normal file → Executable file
@ -1,6 +1,11 @@
|
||||
#! /bin/sh
|
||||
set -e
|
||||
|
||||
# If we're not on an EFI system, do nothing
|
||||
if [ ! -d /sys/firmware/efi ]; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# Must load the confmodule for our template to be installed correctly.
|
||||
. /usr/share/debconf/confmodule
|
||||
|
||||
@ -53,7 +58,6 @@ case $1 in
|
||||
# needed
|
||||
if [ "$bootloader_id" ] && \
|
||||
[ -d "/boot/efi/EFI/$bootloader_id" ] && \
|
||||
[ -d /sys/firmware/efi ] && \
|
||||
which grub-install >/dev/null 2>&1
|
||||
then
|
||||
# Check for some of the options that matter, so we can
|
||||
|
8
debian/signing-template/@final_pkg_name@.postrm.in
vendored
Normal file → Executable file
8
debian/signing-template/@final_pkg_name@.postrm.in
vendored
Normal file → Executable file
@ -1,6 +1,11 @@
|
||||
#! /bin/sh
|
||||
set -e
|
||||
|
||||
# If we're not on an EFI system, do nothing
|
||||
if [ ! -d /sys/firmware/efi ]; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
case @arch@ in
|
||||
i386)
|
||||
SHIM_REMOVE="mmia32.efi fbia32.efi";;
|
||||
@ -39,8 +44,7 @@ case $1 in
|
||||
# If we're being removed, remove the copies installed in the
|
||||
# ESP. grub-install doesn't clean those up for us.
|
||||
if [ "$bootloader_id" ] && \
|
||||
[ -d "/boot/efi/EFI/$bootloader_id" ] && \
|
||||
[ -d /sys/firmware/efi ]; then
|
||||
[ -d "/boot/efi/EFI/$bootloader_id" ]; then
|
||||
|
||||
cd /boot/efi/EFI/$bootloader_id
|
||||
rm -f $SHIM_REMOVE
|
||||
|
Loading…
Reference in New Issue
Block a user