2022-09-02 22:30:42 +00:00
|
|
|
post_install() {
|
2022-09-14 23:54:36 +00:00
|
|
|
_ver=$(echo $1|awk -F'-' '{print $1}')
|
|
|
|
dkms add -m amzn-drivers -v $_ver
|
|
|
|
dkms build -m amzn-drivers -v $_ver
|
2022-09-02 22:30:42 +00:00
|
|
|
printf 'Make sure to add "ena" to the "mkinitcpio.conf" "MODULES" section'
|
|
|
|
printf ' and rebuild the intramfs with "mkinitcpio -P"\n'
|
|
|
|
}
|
|
|
|
|
|
|
|
post_upgrade() {
|
2022-09-14 23:54:36 +00:00
|
|
|
_ver_new=$(echo $1|awk -F'-' '{print $1}')
|
|
|
|
_ver_old=$(echo $2|awk -F'-' '{print $1}')
|
|
|
|
dkms uninstall -m amzn-drivers -v $_ver_old --all
|
|
|
|
dkms remove -m amzn-drivers -v $_ver_old --all
|
|
|
|
dkms unbuild -m amzn-drivers -v $_ver_old --all
|
|
|
|
dkms build -m amzn-drivers -v $_ver_new
|
2022-09-02 22:30:42 +00:00
|
|
|
}
|