Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/modules/signing/preimage.10.extract.sh
diff options
context:
space:
mode:
authorDaniel Drake <dsd@laptop.org>2012-09-10 20:22:55 (GMT)
committer Daniel Drake <dsd@laptop.org>2012-09-17 17:22:38 (GMT)
commit9f20418922d04bc6fe30b2aa1fb5daaabddf4101 (patch)
tree8d05adffc5f285b7514091e29e4c9fd34c966ea2 /modules/signing/preimage.10.extract.sh
parentc5cb6551027da10d04f39ed1c04e166cc4878652 (diff)
Always ship kernel/initramfs in zip files
We now ship the kernel/initramfs in zip files only. This reduces duplication for when images get signed, and it allows us to ship a simplified olpc.fth. This implements the plan here: http://lists.laptop.org/pipermail/devel/2012-March/034439.html This didn't work on first attempt because we hit a firmware bug on XO-1.75 (#12107). Now that we have a fix, and a workaround for old firmware versions, give this change another spin.
Diffstat (limited to 'modules/signing/preimage.10.extract.sh')
-rw-r--r--modules/signing/preimage.10.extract.sh33
1 files changed, 11 insertions, 22 deletions
diff --git a/modules/signing/preimage.10.extract.sh b/modules/signing/preimage.10.extract.sh
index 5a7a471..489f8b4 100644
--- a/modules/signing/preimage.10.extract.sh
+++ b/modules/signing/preimage.10.extract.sh
@@ -14,31 +14,20 @@ mkdir -p $tgt
found=0
echo "Extracting content for signing..."
-if [ -e "$fsmount/boot/bootfw.zip" ]; then
- cp $fsmount/boot/bootfw.zip $tgt
- found=1
-fi
-if [ -e "$fsmount/boot/vmlinuz" ]; then
- cp $fsmount/boot/vmlinuz $tgt/data.img
- zip -j -n .img $tgt/runos.zip $tgt/data.img
- rm -f $tgt/data.img
+copy_out_file() {
+ local name=$1
+ local path="$fsmount"/boot/${1}.zip
+ [ -f "$path"] || return
+ cp $path $tgt
found=1
-fi
-
-if [ -e "$fsmount/boot/initrd.img" ]; then
- cp $fsmount/boot/initrd.img $tgt/data.img
- zip -j -n .img $tgt/runrd.zip $tgt/data.img
- rm -f $tgt/data.img
- found=1
-elif [ -e "$fsmount/boot/olpcrd.img" ]; then
- cp $fsmount/boot/olpcrd.img $tgt/data.img
- zip -j -n .img $tgt/runrd.zip $tgt/data.img
- rm -f $tgt/data.img
- found=1
-fi
+}
+copy_out bootfw
+copy_out runos
+copy_out runrd
+copy_out actos
+copy_out actrd
[ "$found" == "1" ] || exit 0
zip -j $outzip $tgt/*
-