summaryrefslogtreecommitdiff
path: root/uboot-sunxi/uboot-sunxi.install
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2019-09-19 10:19:40 +0200
committerErich Eckner <git@eckner.net>2019-09-19 10:19:40 +0200
commitb24ce6d769146e9dceda85dfb537864fa72e0f53 (patch)
tree6516013686637e673b45beda5c3aaccd48d50b74 /uboot-sunxi/uboot-sunxi.install
parent14ae93e0b1b8a16863ede35bdc4b1e84a8ca363f (diff)
downloadarchlinuxewe.git.save-b24ce6d769146e9dceda85dfb537864fa72e0f53.tar.xz
uboot-sunxi: first trial
Diffstat (limited to 'uboot-sunxi/uboot-sunxi.install')
-rw-r--r--uboot-sunxi/uboot-sunxi.install22
1 files changed, 22 insertions, 0 deletions
diff --git a/uboot-sunxi/uboot-sunxi.install b/uboot-sunxi/uboot-sunxi.install
new file mode 100644
index 00000000..cd4afef4
--- /dev/null
+++ b/uboot-sunxi/uboot-sunxi.install
@@ -0,0 +1,22 @@
+flash_uboot() {
+ echo "A new U-Boot version needs to be flashed onto /dev/mmcblk0."
+ echo "Do you want to do this now? [y|N]"
+ read -r shouldwe
+ if [[ $shouldwe =~ ^([yY][eE][sS]|[yY])$ ]]; then
+ dd if=/boot/u-boot-sunxi-with-spl.bin of=/dev/mmcblk0 bs=1024 seek=8
+ else
+ echo "You can do this later by running:"
+ echo "# dd if=/boot/u-boot-sunxi-with-spl.bin of=/dev/mmcblk0 bs=1024 seek=8"
+ fi
+}
+
+## arg 1: the new package version
+post_install() {
+ flash_uboot
+}
+
+## arg 1: the new package version
+## arg 2: the old package version
+post_upgrade() {
+ flash_uboot
+}