diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 07:40:51 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 07:40:51 +0000 |
commit | 017870ebf041f17c3a8fa10e97d010701431d14b (patch) | |
tree | 370430da4af7aa2682815861078f5bd1c9821b90 /debian/patches/rebuild-modules-on-header-upgrade.patch | |
parent | Adding upstream version 3.0.13. (diff) | |
download | dkms-9c28c7aa7dae1b207f980e1b1f4b3ae2b47806af.tar.xz dkms-9c28c7aa7dae1b207f980e1b1f4b3ae2b47806af.zip |
Adding debian version 3.0.13-1.debian/3.0.13-1debian
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian/patches/rebuild-modules-on-header-upgrade.patch')
-rw-r--r-- | debian/patches/rebuild-modules-on-header-upgrade.patch | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/debian/patches/rebuild-modules-on-header-upgrade.patch b/debian/patches/rebuild-modules-on-header-upgrade.patch new file mode 100644 index 0000000..437bd23 --- /dev/null +++ b/debian/patches/rebuild-modules-on-header-upgrade.patch @@ -0,0 +1,22 @@ +--- a/kernel_postinst.d_dkms.in ++++ b/kernel_postinst.d_dkms.in +@@ -34,6 +34,19 @@ case "${uname_s}" in + ;; + esac + ++case $0 in *header_postinst.d*) ++ # unbuild all autoinstalled modules for this kernel to ensure they get ++ # rebuilt against the updated headers by the next autoinstall below ++ for mod_ver in $(dkms status -k "$inst_kern" 2>/dev/null | grep ': installed' | cut -d, -f1 | sort -u) ++ do ++ dkms_conf="/var/lib/dkms/$mod_ver/source/dkms.conf" ++ autoinstall=$(bash -c 'AUTOINSTALL=; . "'"$dkms_conf"'" >/dev/null 2>&1; echo $AUTOINSTALL') ++ test -n "$autoinstall" || continue ++ dkms unbuild -k "$inst_kern" "$mod_ver" ++ done ++ ;; ++esac ++ + if [ -x @LIBDIR@/dkms_autoinstaller ]; then + exec @LIBDIR@/dkms_autoinstaller start "$inst_kern" + fi |