From a8ab34a9e227bd7202b2bbc88fc6b7fe4a45ee2b Mon Sep 17 00:00:00 2001 From: James Cameron Date: Wed, 29 Oct 2008 11:16:10 +1100 Subject: [PATCH] add copyright, fix fail to boot --- mkbootable.sh | 37 ++++++++++++++++++++++++++++++++++--- 1 file changed, 34 insertions(+), 3 deletions(-) diff --git a/mkbootable.sh b/mkbootable.sh index e1b53bf..e13452d 100755 --- a/mkbootable.sh +++ b/mkbootable.sh @@ -1,4 +1,32 @@ #!/bin/sh +# +# mkbootable.sh, make a bootable file set from a jffs2 image +# Copyright © 2008 James Cameron +# +# This file is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +# + +# Using an image produced by mkjffs2.sh, +# produces a tree of files suitable for erasing and loading an XO, +# typical usage is to mount USB storage and then populate the storage, +# for example: +# +# mount /dev/sdz1 /mnt +# ./mkbootable --output /mnt gnome +# umount /mnt + set -e IMAGE_DEFAULT= @@ -118,10 +146,13 @@ cr ." Starting" \ erase the NAND flash and fill it with the image -update-nand u:\\${IMAGE}.img - \ boot from the NAND flash -boot n:\boot\olpc.fth +: update-and-boot + " update-nand u:\\${IMAGE}.img" evaluate + " boot n:\boot\olpc.fth" evaluate +; + +update-and-boot EOF # TODO: avoid reflashing if already flashed -- 2.39.5