On Sun, Feb 26, 2012 at 08:36:11PM -0800, Frederick Grose wrote:
This apparently has been broken since 15 Feb 2011 with commit
Sorry for not noticing sooner.
Author: Frederick Grose <fgrose(a)sugarlabs.org>
Date: Sun Feb 26 20:05:42 2012 -0800
Restore capability to load the running LiveOS image.
If the source is /dev/live or /dev/sr0, mount it on a loop device.
diff --git a/tools/livecd-iso-to-disk.sh b/tools/livecd-iso-to-disk.sh
index 3ae88a2..3b1add8 100755
@@ -906,13 +906,15 @@ fi
# do some basic sanity checks.
# FIXME: would be better if we had better mountpoints
SRCMNT=$(mktemp -d /media/srctmp.XXXXXX)
-if [ -b "$SRC" ]; then
- mount -o ro "$SRC" $SRCMNT || exitclean
-elif [ -f "$SRC" ]; then
+if [[ -f $SRC || /dev/live == $1 || /dev/sr0 == $1 ]]; then
mount -o loop,ro "$SRC" $SRCMNT || exitclean
+ [[ /dev/live == $1 ]] && imgtype='live'
+elif [[ -b $SRC ]]; then
+ mount -o ro "$SRC" $SRCMNT || exitclean
echo "$SRC is not a file or block device."
imgtype conflicts with the current code where I use it to keep track of
the type of the iso's install image.
Also, I haven't done any testing with using /dev/live or sr0 as a
source -- I'm not sure if that still works.
Brian C. Lane | Anaconda Team | IRC: bcl #anaconda | Port Orchard, WA (PST8PDT)