aboutsummaryrefslogtreecommitdiffstats
path: root/config
diff options
context:
space:
mode:
authorficus <ficus@robocracy.org>2012-11-16 22:08:25 +0100
committerficus <ficus@robocracy.org>2012-11-16 22:08:25 +0100
commit7ca7298d173443d17ae5f029dd308f6de9c975e9 (patch)
tree2e668e9bed8ccd2eaf13a2223973e0f2b8163448 /config
parent388539854c41d62a4d54fc8272230492a8369fc4 (diff)
downloadtorouter-live-7ca7298d173443d17ae5f029dd308f6de9c975e9.tar.gz
torouter-live-7ca7298d173443d17ae5f029dd308f6de9c975e9.zip
update initrd mangling scripts
Diffstat (limited to 'config')
-rwxr-xr-xconfig/hooks/kernel-image.sh.binary26
-rwxr-xr-xconfig/hooks/kernel-image.sh.chroot18
2 files changed, 14 insertions, 30 deletions
diff --git a/config/hooks/kernel-image.sh.binary b/config/hooks/kernel-image.sh.binary
index 69a3b77..d4618dc 100755
--- a/config/hooks/kernel-image.sh.binary
+++ b/config/hooks/kernel-image.sh.binary
@@ -2,26 +2,6 @@
set -e
-echo "Mangling kernel..."
-cd ./binary
-mkdir initrd-repack
-cp live/initrd.img-* initrd-repack
-(cd initrd-repack ; \
- zcat initrd.img-* | cpio -i ; \
- rm -f conf/param.conf ; \
- find . | cpio --quiet -o -H newc | \
- gzip -9 > initrd.img ; \
- cd ..)
-
-cp initrd-repack/initrd.img live/initrd.img
-rm -rf initrd-repack
-
-(cd live; \
- cp ../usr/lib/linux-image-*/kirkwood-dreamplug.dtb dtb ; \
- cat vmlinuz-* dtb >> temp-kernel ; \
- mkimage -A arm -O linux -T kernel -n "Debian kernel (unknown version)" \
- -C none -a 0x8000 -e 0x8000 -d temp-kernel uImage ; \
- rm -f temp-kernel ; \
- mkimage -A arm -O linux -T ramdisk -C gzip -a 0x0 -e 0x0 \
- -n "Debian ramdisk (unknown version)" \
- -d initrd.img uInitrd )
+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 28b7f44..67059c4 100755
--- a/config/hooks/kernel-image.sh.chroot
+++ b/config/hooks/kernel-image.sh.chroot
@@ -7,13 +7,17 @@ echo "Trying to flashing kernel..."
/usr/sbin/flash-kernel || echo "Failed to flash kernel! Don't worry, will mangle"
echo "Mangling kernel..."
-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
+
+# 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
(cd /boot ; \
cp /usr/lib/linux-image-*/kirkwood-dreamplug.dtb dtb ; \