2013-11-12 16:07:02 +00:00
|
|
|
post_install() {
|
|
|
|
dkms install -m 8192cu -v ${1%%-*}
|
2013-04-15 03:31:30 +00:00
|
|
|
}
|
2013-11-12 16:07:02 +00:00
|
|
|
pre_upgrade() {
|
|
|
|
local curver=${2%%-*}
|
|
|
|
# $2 is unset due to a bug. See, https://bugs.archlinux.org/task/32278
|
|
|
|
# Query current version using pacman as fallback
|
|
|
|
[ -n "$curver" ] || curver=$(pacman -Q dkms-8192cu | cut -d' ' -f2)
|
|
|
|
pre_remove $curver
|
2013-04-15 03:31:30 +00:00
|
|
|
}
|
2013-11-12 16:07:02 +00:00
|
|
|
post_upgrade() {
|
|
|
|
post_install ${1%%-*}
|
2013-04-15 03:31:30 +00:00
|
|
|
}
|
2013-11-12 16:07:02 +00:00
|
|
|
pre_remove() {
|
|
|
|
dkms remove -m 8192cu -v ${1%%-*} --all
|
2013-04-15 03:31:30 +00:00
|
|
|
}
|