aboutsummaryrefslogtreecommitdiffstats
path: root/config/hooks
diff options
context:
space:
mode:
Diffstat (limited to 'config/hooks')
-rwxr-xr-xconfig/hooks/kernel-image.sh.binary7
-rwxr-xr-xconfig/hooks/kernel-image.sh.chroot25
2 files changed, 13 insertions, 19 deletions
diff --git a/config/hooks/kernel-image.sh.binary b/config/hooks/kernel-image.sh.binary
deleted file mode 100755
index d4618dc..0000000
--- a/config/hooks/kernel-image.sh.binary
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/bin/sh
-
-set -e
-
-echo "re-copying kernel and initrd from chroot..."
-cp chroot/boot/uImage binary/live/
-cp chroot/boot/uInitrd binary/live/
diff --git a/config/hooks/kernel-image.sh.chroot b/config/hooks/kernel-image.sh.chroot
index 67059c4..2c15971 100755
--- a/config/hooks/kernel-image.sh.chroot
+++ b/config/hooks/kernel-image.sh.chroot
@@ -4,20 +4,17 @@ set -e
# TODO: this seems to be a null-op... flash-kernel is symlinked to `true`?
echo "Trying to flashing kernel..."
-/usr/sbin/flash-kernel || echo "Failed to flash kernel! Don't worry, will mangle"
+#/usr/sbin/flash-kernel || echo "Failed to flash kernel! Don't worry, will mangle"
+/usr/sbin/flash-kernel
echo "Mangling kernel..."
-
-# XXX: temporary
-cp /boot/initrd.img-* /boot/initrd.img
-
-#mkdir /tmp/initrd-repack
-#(cd /tmp/initrd-repack ; \
-# zcat /boot/initrd.img-* | cpio -i ; \
-# rm -f conf/param.conf ; \
-# find . | cpio --quiet -o -H newc | \
-# gzip -9 > /boot/initrd.img)
-#rm -rf /tmp/initrd-repack
+mkdir /tmp/initrd-repack
+(cd /tmp/initrd-repack ; \
+ zcat /boot/initrd.img-* | cpio -i ; \
+ rm -f conf/param.conf ; \
+ find . | cpio --quiet -o -H newc | \
+ gzip -9 > /boot/initrd.img)
+rm -rf /tmp/initrd-repack
(cd /boot ; \
cp /usr/lib/linux-image-*/kirkwood-dreamplug.dtb dtb ; \
@@ -28,3 +25,7 @@ cp /boot/initrd.img-* /boot/initrd.img
mkimage -A arm -O linux -T ramdisk -C gzip -a 0x0 -e 0x0 \
-n "Debian ramdisk (unknown version)" \
-d initrd.img uInitrd )
+
+echo "Creating /live and copying in boot images..."
+mkdir /live
+cp /boot/uInitrd /boot/uImage /boot/dtb /live