diff options
Diffstat (limited to 'tools/gator/debian/gator-module-dkms.prerm')
-rwxr-xr-x | tools/gator/debian/gator-module-dkms.prerm | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/tools/gator/debian/gator-module-dkms.prerm b/tools/gator/debian/gator-module-dkms.prerm new file mode 100755 index 00000000000..cf0b5f99da7 --- /dev/null +++ b/tools/gator/debian/gator-module-dkms.prerm @@ -0,0 +1,29 @@ +#!/bin/sh + +NAME=gator-module +PACKAGE_NAME=$NAME-dkms +VERSION=`dpkg-query -W -f='${Version}' $PACKAGE_NAME | awk -F "-" '{print $1}' | cut -d\: -f2` + +set -e + +case "$1" in + remove|upgrade|deconfigure) + if [ "`dkms status -m $NAME`" ]; then + dkms remove -m $NAME -v $VERSION --all + fi + ;; + + failed-upgrade) + ;; + + *) + echo "prerm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +#DEBHELPER# + +exit 0 + + |