grub.install 782 B

1234567891011121314151617181920212223242526272829
  1. #!/bin/sh
  2. post_upgrade() {
  3. # We used to package /boot/grub/grub.cfg, but there is no reason to.
  4. # Remove the file from package, but move real file back in place.
  5. if [ ! -f /boot/grub/grub.cfg -a -f /boot/grub/grub.cfg.pacsave ]; then
  6. mv /boot/grub/grub.cfg.pacsave /boot/grub/grub.cfg
  7. fi
  8. # return if old package version greater 2:2.06-0...
  9. (( $(vercmp $2 '2:2.06-0') > 0 )) && return
  10. if [[ -e /sys/firmware/efi/efivars ]]; then
  11. cat <<EOM
  12. :: Grub does no longer support side-loading modules when secure boot is
  13. enabled. Thus booting will fail, unless you have an efi executable
  14. 'grubx64.efi' with bundled modules.
  15. EOM
  16. fi
  17. }
  18. post_install() {
  19. cat <<EOM
  20. :: Generate your bootloader configuration with:
  21. grub-mkconfig -o /boot/grub/grub.cfg
  22. EOM
  23. }