]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blame - debian/templates/extra.postrm.in
HID: i2c-hid: Fix flooded incomplete report after S3 on Rayd touchscreen
[mirror_ubuntu-bionic-kernel.git] / debian / templates / extra.postrm.in
CommitLineData
fbf28672
AW
1#!/bin/sh
2set -e
3
4version=@abiname@@localversion@
5image_path=/boot/@image-stem@-$version
6
7if [ "$1" != remove ]; then
8 exit 0
9fi
10
11depmod -a -F /boot/System.map-$version $version 2>/dev/null || true
0b151c76
AW
12#
13# We should be rebuilding the initramfs here on removal to pare down the
14# initramfs if it contains any of the objects we just removed. But people
15# commonly remove kernels in order to free space in /boot, and rebuilding the
16# initramfs now risks ENOSPC when we are trying to make space. The files we
17# leave lying about could be confusing, but we trade that against safety on
18# removal.
19#
20#if [ -d /etc/kernel/postinst.d ]; then
21# # We want to behave as if linux-image (without us) was installed, therefore
22# # we do not want the postinst support to know we are being removed, claim
23# # this is an installation event.
24# mkdir -p /usr/lib/linux/triggers
25# cat - >/usr/lib/linux/triggers/$version <<EOF
26#DEB_MAINT_PARAMS="configure" run-parts --report --exit-on-error --arg=$version \
27# --arg="$image_path" /etc/kernel/postinst.d
28#EOF
29# dpkg-trigger --no-await linux-update-$version
30#fi
fbf28672
AW
31
32exit 0