This prevents the prerm from failing if there are modules installed
under other versions, but not the one we are removing.
---
 debian/scripts/prerm-dkms |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/debian/scripts/prerm-dkms b/debian/scripts/prerm-dkms
index 6ae2988..6e93a1b 100644
--- a/debian/scripts/prerm-dkms
+++ b/debian/scripts/prerm-dkms
@@ -3,7 +3,7 @@ DKMS_VERSION=#MODULE_VERSION#
 
 case "$1" in
     remove|upgrade|deconfigure)
-      if [  "$(dkms status -m $DKMS_NAME)" ]; then
+      if [  "$(dkms status -m $DKMS_NAME -v $DKMS_VERSION)" ]; then
          dkms remove -m $DKMS_NAME -v $DKMS_VERSION --all
       fi
     ;;
-- 
1.7.0


_______________________________________________
Pkg-dkms-maint mailing list
[email protected]
http://lists.alioth.debian.org/mailman/listinfo/pkg-dkms-maint

Reply via email to