Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/sh
- objcopy --add-section .osrel=/etc/os-release --change-section-vma .osrel=0x20000 --add-section .cmdline=/boot/efistub/cmdline.txt --change-section-vma .cmdline=0x30000 --add-section .linux=/boot/vmlinuz --change-section-vma .linux=0x40000 --add-section .initrd=/boot/initrd.img --change-section-vma .initrd=0x3000000 -S /usr/lib/systemd/boot/efi/linuxx64.efi.stub /boot/efistub/kernel.efi
- if [ -d /boot/efikeys ]
- then
- sbsign --key /boot/efikeys/db.key --cert /boot/efikeys/db.crt --output /boot/efistub/kernel.efi /boot/efistub/kernel.efi
- sync
- sbverify --cert /boot/efikeys/db.crt /boot/efistub/kernel.efi
- fi
- knf="`sudo readlink /boot/vmlinuz`"
- knb="`sudo basename $knf`"
- cp -f /boot/efistub/kernel.efi /boot/efistub/kernel.$knb.efi
- cp -f /boot/efistub/kernel.efi /boot/efi/EFI/Mint/kernel.efi
- cp -f /boot/efistub/kernel.efi /boot/efi/EFI/Boot/Bootx64.efi
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement