1
0
Fork 0
linux-spica-e3-1230v3/linux-spica.install

38 lines
1.7 KiB
Plaintext

pkgname=linux-spica
kernver=4.10.8spica-dirty
#bootdevice="BOOT_IMAGE=/boot/vmlinuz-$pkgname root=UUID=d670564f-2cb3-4981-9d51-6ed9c1327d47"
#option="rw quiet clocksource=hpet initrd=EFI/spi-ca/initrd intel_iommu=on pci-stub.ids=1002:683f,1002:aab0 vfio_iommu_type1.allow_unsafe_interrupts=1,kvm.ignore_msrs=1"
#option="rw quiet clocksource=hpet initrd=EFI/spi-ca/initrd quiet intremap=no_x2apic_optout zswap.enabled=1 zswap.max_pool_percent=25 zswap.compressor=lz4"
post_install () {
echo ">"
echo "> Updating module dependencies. Please wait ..."
depmod $kernver
echo ">"
echo "> Generating initramfs, using mkinitcpio. Please wait..."
echo ">"
mkinitcpio -p $pkgname
# echo "> Modifing efibootmgr..."
# efibootmgr|awk 'match($0,/^Boot([0-9a-fA-F]{4})\* spi-ca_v(.+)$/,m){printf "efibootmgr -b %s -B;echo \">> remove entry : %s\";",m[1],m[2]}'|sh
# echo "> Copy efistub from boot"
# cp -fv "boot/vmlinuz-$pkgname" "boot/efi/EFI/spi-ca/kernel.efi"
# cp -fv "boot/initramfs-$pkgname.img" "boot/efi/EFI/spi-ca/initrd"
# echo "> Registering efistub "
#echo 'efibootmgr -c -g -d /dev/sda -p 1 -L "spi-ca_v$kernver" -l "\EFI\spi-ca\kernel.efi" #-u "$bootdevice $option"'
# efibootmgr -c -g -d /dev/sde -p 1 -L "spi-ca_v$kernver" -l "\EFI\spi-ca\kernel" # -u "$bootdevice $option"
# echo "> Reordering Bootorder..."
# newentry=`efibootmgr|awk 'match($0,/^Boot([0-9a-fA-F]{4})\* spi-ca_v(.+)$/,m){print m[1]}'`
# prebootorder=`efibootmgr |grep BootOrder |cut -d : -f 2 |tr -d ' '`
# efibootmgr -O
# efibootmgr -o ${newentry},${prebootorder}
echo "> OK!"
}
post_upgrade() {
post_install
}
post_remove() {
rm -f -- "boot/initramfs-$pkgname.img"
}