mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-08 22:45:43 +00:00
31 lines
779 B
Text
31 lines
779 B
Text
# arg 1: the new package version
|
|
# arg 2: the old package versio
|
|
|
|
KERNEL_VERSION=3.8.0-ARCH
|
|
|
|
flash_kernel() {
|
|
echo "A new kernel version needs to be flashed onto /dev/mmcblk1p1."
|
|
echo "Do you want to do this now? [y|N]"
|
|
read -r shouldwe
|
|
if [[ $shouldwe =~ ^([yY][eE][sS]|[yY])$ ]]; then
|
|
dd if=/boot/vmlinux.kpart of=/dev/mmcblk1p1
|
|
sync
|
|
else
|
|
echo "You can do this later by running:"
|
|
echo "# dd if=/boot/vmlinux.kpart of=/dev/mmcblk1p1"
|
|
fi
|
|
}
|
|
|
|
post_install () {
|
|
# updating module dependencies
|
|
echo ">>> Updating module dependencies. Please wait ..."
|
|
depmod ${KERNEL_VERSION}
|
|
flash_kernel
|
|
}
|
|
|
|
post_upgrade() {
|
|
# updating module dependencies
|
|
echo ">>> Updating module dependencies. Please wait ..."
|
|
depmod ${KERNEL_VERSION}
|
|
flash_kernel
|
|
}
|