From 7ca7298d173443d17ae5f029dd308f6de9c975e9 Mon Sep 17 00:00:00 2001 From: ficus Date: Fri, 16 Nov 2012 22:08:25 +0100 Subject: update initrd mangling scripts --- config/hooks/kernel-image.sh.binary | 26 +++----------------------- config/hooks/kernel-image.sh.chroot | 18 +++++++++++------- 2 files changed, 14 insertions(+), 30 deletions(-) (limited to 'config') 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 ; \ -- cgit v1.2.3