summaryrefslogtreecommitdiff
path: root/community/vhba-module/vhba-module.install
diff options
context:
space:
mode:
Diffstat (limited to 'community/vhba-module/vhba-module.install')
-rw-r--r--community/vhba-module/vhba-module.install17
1 files changed, 8 insertions, 9 deletions
diff --git a/community/vhba-module/vhba-module.install b/community/vhba-module/vhba-module.install
index 8458b2ae7..d6e4d08d7 100644
--- a/community/vhba-module/vhba-module.install
+++ b/community/vhba-module/vhba-module.install
@@ -1,21 +1,20 @@
-post_upgrade() {
- ! grep -q 'cdemu' /etc/group && groupadd cdemu
+_updatemod() {
echo " > Updating module dependencies..."
- EXTRAMODULES='extramodules-3.4-ARCH'
+ EXTRAMODULES='extramodules-3.6-ARCH'
depmod $(cat /usr/lib/modules/$EXTRAMODULES/version)
}
-
post_install() {
- echo " > Adding 'cdemu' group"
- ! grep -q 'cdemu' /etc/group && groupadd cdemu
- echo " > Add 'vhba' to your modules array to autoload it"
post_upgrade
}
+post_upgrade() {
+ getent group cdemu &>/dev/null || groupadd -r cdemu
+ _updatemod
+}
+
post_remove() {
- post_upgrade
- echo "Removing 'cdemu' group"
+ _updatemod
groupdel cdemu
}