|
|
Subject: [PATCH 4/7] move syslinux and isolinux directories under /boot - msg#00174
This is a multi-part message in MIME format.This patch moves the /isolinux directory on the livecd to
/boot/isolinux, and the /syslinux directory on liveusb to /boot/syslinux.
I think that this will be make the livecd appear less intimidating to
new non-linux-guru users. Aesthetics.
Since I don't use ppc myself, I didn't attempt to also move the /ppc dir
to /boot/ppc on the ppc side. But I would recommend that as well if
possible.
-dmc
diff -Naur livecd.3.squashed_image_to_LiveOS/creator/isotostick.sh
livecd.4.syslinux_to_boot/creator/isotostick.sh
--- livecd.3.squashed_image_to_LiveOS/creator/isotostick.sh 2007-09-21
07:08:32.000000000 +0000
+++ livecd.4.syslinux_to_boot/creator/isotostick.sh 2007-09-21
07:28:18.000000000 +0000
@@ -132,7 +132,7 @@
if ! syslinux 2>&1 | grep -qe -d; then
SYSLINUXPATH=""
else
- SYSLINUXPATH="syslinux"
+ SYSLINUXPATH="boot/syslinux"
fi
}
@@ -201,7 +201,7 @@
fi
echo "Copying live image to USB stick"
-if [ ! -d $USBMNT/$SYSLINUXPATH ]; then mkdir $USBMNT/$SYSLINUXPATH ; fi
+if [ ! -d $USBMNT/$SYSLINUXPATH ]; then mkdir -p $USBMNT/$SYSLINUXPATH ; fi
if [ ! -d $USBMNT/LiveOS ]; then mkdir $USBMNT/LiveOS ; fi
# cases without /LiveOS are legacy detection, remove for F10
if [ -f $CDMNT/LiveOS/squashfs.img ]; then
@@ -219,7 +219,13 @@
cp $CDMNT/osmin.gz $USBMNT/LiveOS/osmin.gz || exitclean
fi
-cp $CDMNT/isolinux/* $USBMNT/$SYSLINUXPATH
+# case without /boot is legacy detection, remove for F10
+if [ -d $CDMNT/boot/isolinux ]; then
+ cp $CDMNT/boot/isolinux/* $USBMNT/$SYSLINUXPATH
+else
+ cp $CDMNT/isolinux/* $USBMNT/$SYSLINUXPATH
+fi
+
echo "Updating boot config file"
# adjust label and fstype
@@ -240,7 +246,7 @@
# extlinux expects the config to be named extlinux.conf
# and has to be run with the file system mounted
mv $USBMNT/$SYSLINUXPATH/isolinux.cfg $USBMNT/$SYSLINUXPATH/extlinux.conf
- extlinux -i $USBMNT/syslinux
+ extlinux -i $USBMNT/$SYSLINUXPATH
cleanup
fi
diff -Naur livecd.3.squashed_image_to_LiveOS/creator/livecd-creator
livecd.4.syslinux_to_boot/creator/livecd-creator
--- livecd.3.squashed_image_to_LiveOS/creator/livecd-creator 2007-09-21
07:47:23.000000000 +0000
+++ livecd.4.syslinux_to_boot/creator/livecd-creator 2007-09-21
07:47:45.000000000 +0000
@@ -1088,15 +1088,16 @@
"""ImageCreator for x86 machines"""
def configureBootloader(self):
"""configure the boot loader"""
- os.makedirs(self.build_dir + "/out/isolinux")
+ os.makedirs(self.build_dir + "/out/boot")
+ os.makedirs(self.build_dir + "/out/boot/isolinux")
shutil.copyfile("%s/install_root/boot/vmlinuz-%s"
%(self.build_dir, self.get_kernel_version()),
- "%s/out/isolinux/vmlinuz" %(self.build_dir,))
+ "%s/out/boot/isolinux/vmlinuz" %(self.build_dir,))
shutil.copyfile("%s/install_root/boot/livecd-initramfs.img"
%(self.build_dir,),
- "%s/out/isolinux/initrd.img" %(self.build_dir,))
+ "%s/out/boot/isolinux/initrd.img" %(self.build_dir,))
os.unlink("%s/install_root/boot/livecd-initramfs.img"
%(self.build_dir,))
@@ -1116,7 +1117,7 @@
isXen = False
xen = glob.glob("%s/install_root/boot/xen.gz-*" %(self.build_dir,))
if len(xen) > 0:
- shutil.copyfile(xen[0], "%s/out/isolinux/xen.gz"
%(self.build_dir,))
+ shutil.copyfile(xen[0], "%s/out/boot/isolinux/xen.gz"
%(self.build_dir,))
syslinuxfiles.append("mboot.c32")
isXen = True
@@ -1125,11 +1126,11 @@
if not os.path.isfile(path):
raise InstallationError("syslinux not installed : %s not
found" % path)
- shutil.copy(path, "%s/out/isolinux/%s" % (self.build_dir, p))
+ shutil.copy(path, "%s/out/boot/isolinux/%s" % (self.build_dir, p))
if
os.path.exists("%s/install_root/usr/lib/anaconda-runtime/syslinux-vesa-splash.jpg"
%(self.build_dir,)):
shutil.copy("%s/install_root/usr/lib/anaconda-runtime/syslinux-vesa-splash.jpg"
%(self.build_dir,),
- "%s/out/isolinux/splash.jpg" %(self.build_dir,))
+ "%s/out/boot/isolinux/splash.jpg" %(self.build_dir,))
have_background = "menu background splash.jpg"
else:
have_background = ""
@@ -1179,7 +1180,7 @@
memtest = glob.glob("%s/install_root/boot/memtest86*"
%(self.build_dir,))
if len(memtest) > 0:
- shutil.copy(memtest[0], "%s/out/isolinux/memtest"
%(self.build_dir,))
+ shutil.copy(memtest[0], "%s/out/boot/isolinux/memtest"
%(self.build_dir,))
cfg += """label memtest
menu label Memory Test
kernel memtest
@@ -1190,7 +1191,7 @@
menu label Boot from local drive
localboot 0xffff"""
- cfgf = open("%s/out/isolinux/isolinux.cfg" %(self.build_dir,), "w")
+ cfgf = open("%s/out/boot/isolinux/isolinux.cfg" %(self.build_dir,),
"w")
cfgf.write(cfg)
cfgf.close()
@@ -1199,8 +1200,8 @@
def createIso(self):
"""Write out the live CD ISO."""
rc = subprocess.call(["/usr/bin/mkisofs", "-o", "%s.iso"
%(self.fs_label,),
- "-b", "isolinux/isolinux.bin",
- "-c", "isolinux/boot.cat",
+ "-b", "boot/isolinux/isolinux.bin",
+ "-c", "boot/isolinux/boot.cat",
"-no-emul-boot", "-boot-load-size", "4",
"-boot-info-table",
"-J", "-r", "-hide-rr-moved",
"-hide-joliet-trans-tbl",
Thread at a glance:
Previous Message by Date:
[PATCH 5/7] rename os.img to ext3fs.img for consistency
This is a multi-part message in MIME format.This patch renames os.img in the embedded squashfs.img to ext3fs.img, to
be consistent with the name choice of ext3fs.img in the
--skip-compression case.
-dmc
diff -Naur livecd.4.syslinux_to_boot/creator/livecd-creator
livecd.5.os_to_ext3fs/creator/livecd-creator
--- livecd.4.syslinux_to_boot/creator/livecd-creator 2007-09-21
07:47:45.000000000 +0000
+++ livecd.5.os_to_ext3fs/creator/livecd-creator 2007-09-21
07:49:01.000000000 +0000
@@ -408,12 +408,12 @@
# legacy LiveOS filesystem layout support, remove for F9 or F10
if os.path.exists(self.build_dir + "/base_on_squashfs/os.img"):
os_image = self.build_dir + "/base_on_squashfs/os.img"
- elif os.path.exists(self.build_dir +
"/base_on_squashfs/LiveOS/os.img"):
- os_image = self.build_dir + "/base_on_squashfs/LiveOS/os.img"
+ elif os.path.exists(self.build_dir +
"/base_on_squashfs/LiveOS/ext3fs.img"):
+ os_image = self.build_dir +
"/base_on_squashfs/LiveOS/ext3fs.img"
else:
raise InstallationError("'%s' is not a valid live CD ISO :
os.img doesn't exist" % base_on)
- shutil.copyfile(os_image, self.build_dir + "/data/LiveOS/os.img")
+ shutil.copyfile(os_image, self.build_dir +
"/data/LiveOS/ext3fs.img")
finally:
# unmount and tear down the mount points and loop devices used
squashloop.cleanup()
@@ -446,10 +446,10 @@
# get backing ext3 image if we're based this build on an existing
live CD ISO
self.base_on_iso(base_on)
- self.instloop = LoopbackMount("%s/data/LiveOS/os.img"
%(self.build_dir,),
+ self.instloop = LoopbackMount("%s/data/LiveOS/ext3fs.img"
%(self.build_dir,),
"%s/install_root" %(self.build_dir,))
else:
- self.instloop = SparseExt3LoopbackMount("%s/data/LiveOS/os.img"
+ self.instloop = SparseExt3LoopbackMount("%s/data/LiveOS/ext3fs.img"
%(self.build_dir,),
"%s/install_root"
%(self.build_dir,),
@@ -931,7 +931,7 @@
if ret != 0:
raise InstallationError("mksquashfs exited with error (%d)"
%(ret,))
else:
- shutil.move("%s/data/LiveOS/os.img" %(self.build_dir,),
+ shutil.move("%s/data/LiveOS/ext3fs.img" %(self.build_dir,),
"%s/out/LiveOS/ext3fs.img" %(self.build_dir,))
def _getBlockCountOfExt2FS(self, filesystem):
@@ -981,7 +981,7 @@
# resize2fs-to-uncompressed-size (with implicit resparsification)
#
def cleanupDeleted(self):
- image = "%s/data/LiveOS/os.img" %(self.build_dir,)
+ image = "%s/data/LiveOS/ext3fs.img" %(self.build_dir,)
subprocess.call(["/sbin/e2fsck", "-f", "-y", image])
@@ -1002,8 +1002,8 @@
#
# genMinInstDelta: generates an osmin overlay file to sit alongside
- # os.img. liveinst may then detect the existence of
- # osmin, and use it to create a minimized os.img
+ # ext3fs.img. liveinst may then detect the existence of
+ # osmin, and use it to create a minimized ext3fs.img
# which can be installed more quickly, and to smaller
# destination volumes.
#
@@ -1017,7 +1017,7 @@
os.close(fd)
# associate os image with loop device
- osloop = LoopbackMount("%s/data/LiveOS/os.img" %(self.build_dir,), \
+ osloop = LoopbackMount("%s/data/LiveOS/ext3fs.img" %(self.build_dir,),
\
"None")
osloop.loopsetup()
diff -Naur livecd.4.syslinux_to_boot/creator/mayflower
livecd.5.os_to_ext3fs/creator/mayflower
--- livecd.4.syslinux_to_boot/creator/mayflower 2007-09-21 07:05:02.000000000
+0000
+++ livecd.5.os_to_ext3fs/creator/mayflower 2007-09-21 07:46:02.000000000
+0000
@@ -706,7 +706,7 @@
mount -n -t squashfs -o ro \$SQUASHED_LOOPDEV /squashfs
BASE_LOOPDEV=\$( losetup -f )
- losetup \$BASE_LOOPDEV /squashfs/LiveOS/os.img
+ losetup \$BASE_LOOPDEV /squashfs/LiveOS/ext3fs.img
umount -l /squashfs
if [ "\$live_ram" == "0" ] ; then
Next Message by Date:
[PATCH 6/7] rename ext3fs.img to ext3.img for consistency
This is a multi-part message in MIME format.This patch renames the ext3fs.img file to ext3.img, to conform to a
syntax of <fstype>.img, along with the existing squashfs.img. This may
be useful for future code simplification. I like it.
-dmc
diff -Naur livecd.5.os_to_ext3fs/creator/isotostick.sh
livecd.6.ext3fs_to_ext3/creator/isotostick.sh
--- livecd.5.os_to_ext3fs/creator/isotostick.sh 2007-09-21 07:28:18.000000000
+0000
+++ livecd.6.ext3fs_to_ext3/creator/isotostick.sh 2007-09-21
08:14:46.000000000 +0000
@@ -203,13 +203,15 @@
echo "Copying live image to USB stick"
if [ ! -d $USBMNT/$SYSLINUXPATH ]; then mkdir -p $USBMNT/$SYSLINUXPATH ; fi
if [ ! -d $USBMNT/LiveOS ]; then mkdir $USBMNT/LiveOS ; fi
-# cases without /LiveOS are legacy detection, remove for F10
+# cases without /LiveOS and ext3fs are legacy detection, remove for F10
if [ -f $CDMNT/LiveOS/squashfs.img ]; then
cp $CDMNT/LiveOS/squashfs.img $USBMNT/LiveOS/squashfs.img || exitclean
elif [ -f $CDMNT/squashfs.img ]; then
cp $CDMNT/squashfs.img $USBMNT/LiveOS/squashfs.img || exitclean
elif [ -f $CDMNT/LiveOS/ext3fs.img ]; then
cp $CDMNT/LiveOS/ext3fs.img $USBMNT/LiveOS/ext3fs.img || exitclean
+elif [ -f $CDMNT/LiveOS/ext3.img ]; then
+ cp $CDMNT/LiveOS/ext3.img $USBMNT/LiveOS/ext3.img || exitclean
elif [ -f $CDMNT/ext3fs.img ]; then
cp $CDMNT/ext3fs.img $USBMNT/LiveOS/ext3fs.img || exitclean
fi
diff -Naur livecd.5.os_to_ext3fs/creator/livecd-creator
livecd.6.ext3fs_to_ext3/creator/livecd-creator
--- livecd.5.os_to_ext3fs/creator/livecd-creator 2007-09-21
07:49:01.000000000 +0000
+++ livecd.6.ext3fs_to_ext3/creator/livecd-creator 2007-09-21
08:16:21.000000000 +0000
@@ -408,12 +408,12 @@
# legacy LiveOS filesystem layout support, remove for F9 or F10
if os.path.exists(self.build_dir + "/base_on_squashfs/os.img"):
os_image = self.build_dir + "/base_on_squashfs/os.img"
- elif os.path.exists(self.build_dir +
"/base_on_squashfs/LiveOS/ext3fs.img"):
- os_image = self.build_dir +
"/base_on_squashfs/LiveOS/ext3fs.img"
+ elif os.path.exists(self.build_dir +
"/base_on_squashfs/LiveOS/ext3.img"):
+ os_image = self.build_dir + "/base_on_squashfs/LiveOS/ext3.img"
else:
raise InstallationError("'%s' is not a valid live CD ISO :
os.img doesn't exist" % base_on)
- shutil.copyfile(os_image, self.build_dir +
"/data/LiveOS/ext3fs.img")
+ shutil.copyfile(os_image, self.build_dir + "/data/LiveOS/ext3.img")
finally:
# unmount and tear down the mount points and loop devices used
squashloop.cleanup()
@@ -446,10 +446,10 @@
# get backing ext3 image if we're based this build on an existing
live CD ISO
self.base_on_iso(base_on)
- self.instloop = LoopbackMount("%s/data/LiveOS/ext3fs.img"
%(self.build_dir,),
+ self.instloop = LoopbackMount("%s/data/LiveOS/ext3.img"
%(self.build_dir,),
"%s/install_root" %(self.build_dir,))
else:
- self.instloop = SparseExt3LoopbackMount("%s/data/LiveOS/ext3fs.img"
+ self.instloop = SparseExt3LoopbackMount("%s/data/LiveOS/ext3.img"
%(self.build_dir,),
"%s/install_root"
%(self.build_dir,),
@@ -931,8 +931,8 @@
if ret != 0:
raise InstallationError("mksquashfs exited with error (%d)"
%(ret,))
else:
- shutil.move("%s/data/LiveOS/ext3fs.img" %(self.build_dir,),
- "%s/out/LiveOS/ext3fs.img" %(self.build_dir,))
+ shutil.move("%s/data/LiveOS/ext3.img" %(self.build_dir,),
+ "%s/out/LiveOS/ext3.img" %(self.build_dir,))
def _getBlockCountOfExt2FS(self, filesystem):
def parseField(output, field):
@@ -981,7 +981,7 @@
# resize2fs-to-uncompressed-size (with implicit resparsification)
#
def cleanupDeleted(self):
- image = "%s/data/LiveOS/ext3fs.img" %(self.build_dir,)
+ image = "%s/data/LiveOS/ext3.img" %(self.build_dir,)
subprocess.call(["/sbin/e2fsck", "-f", "-y", image])
@@ -1002,8 +1002,8 @@
#
# genMinInstDelta: generates an osmin overlay file to sit alongside
- # ext3fs.img. liveinst may then detect the existence of
- # osmin, and use it to create a minimized ext3fs.img
+ # ext3.img. liveinst may then detect the existence of
+ # osmin, and use it to create a minimized ext3.img
# which can be installed more quickly, and to smaller
# destination volumes.
#
@@ -1017,7 +1017,7 @@
os.close(fd)
# associate os image with loop device
- osloop = LoopbackMount("%s/data/LiveOS/ext3fs.img" %(self.build_dir,),
\
+ osloop = LoopbackMount("%s/data/LiveOS/ext3.img" %(self.build_dir,), \
"None")
osloop.loopsetup()
@@ -1041,7 +1041,7 @@
"/dev/mapper/livecd-creator-%d" %(os.getpid(),),
"%dK" %(self.minimized_image_size,)])
if rc != 0:
- raise InstallationError("Could not shrink ext3fs image")
+ raise InstallationError("Could not shrink ext3 image")
# calculate how much delta data to keep
dmsetupOutput = subprocess.Popen(['/sbin/dmsetup', 'status',
diff -Naur livecd.5.os_to_ext3fs/creator/mayflower
livecd.6.ext3fs_to_ext3/creator/mayflower
--- livecd.5.os_to_ext3fs/creator/mayflower 2007-09-21 07:46:02.000000000
+0000
+++ livecd.6.ext3fs_to_ext3/creator/mayflower 2007-09-21 08:15:09.000000000
+0000
@@ -654,8 +654,8 @@
# we might have an uncompressed embedded ext3 to use as rootfs (uncompressed
live)
#
-if [ -e /sysroot/LiveOS/ext3fs.img ]; then
- EXT3FS="/sysroot/LiveOS/ext3fs.img"
+if [ -e /sysroot/LiveOS/ext3.img ]; then
+ EXT3FS="/sysroot/LiveOS/ext3.img"
fi
if [ -n "\$EXT3FS" ] ; then
@@ -706,7 +706,7 @@
mount -n -t squashfs -o ro \$SQUASHED_LOOPDEV /squashfs
BASE_LOOPDEV=\$( losetup -f )
- losetup \$BASE_LOOPDEV /squashfs/LiveOS/ext3fs.img
+ losetup \$BASE_LOOPDEV /squashfs/LiveOS/ext3.img
umount -l /squashfs
if [ "\$live_ram" == "0" ] ; then
Previous Message by Thread:
[PATCH 5/7] rename os.img to ext3fs.img for consistency
This is a multi-part message in MIME format.This patch renames os.img in the embedded squashfs.img to ext3fs.img, to
be consistent with the name choice of ext3fs.img in the
--skip-compression case.
-dmc
diff -Naur livecd.4.syslinux_to_boot/creator/livecd-creator
livecd.5.os_to_ext3fs/creator/livecd-creator
--- livecd.4.syslinux_to_boot/creator/livecd-creator 2007-09-21
07:47:45.000000000 +0000
+++ livecd.5.os_to_ext3fs/creator/livecd-creator 2007-09-21
07:49:01.000000000 +0000
@@ -408,12 +408,12 @@
# legacy LiveOS filesystem layout support, remove for F9 or F10
if os.path.exists(self.build_dir + "/base_on_squashfs/os.img"):
os_image = self.build_dir + "/base_on_squashfs/os.img"
- elif os.path.exists(self.build_dir +
"/base_on_squashfs/LiveOS/os.img"):
- os_image = self.build_dir + "/base_on_squashfs/LiveOS/os.img"
+ elif os.path.exists(self.build_dir +
"/base_on_squashfs/LiveOS/ext3fs.img"):
+ os_image = self.build_dir +
"/base_on_squashfs/LiveOS/ext3fs.img"
else:
raise InstallationError("'%s' is not a valid live CD ISO :
os.img doesn't exist" % base_on)
- shutil.copyfile(os_image, self.build_dir + "/data/LiveOS/os.img")
+ shutil.copyfile(os_image, self.build_dir +
"/data/LiveOS/ext3fs.img")
finally:
# unmount and tear down the mount points and loop devices used
squashloop.cleanup()
@@ -446,10 +446,10 @@
# get backing ext3 image if we're based this build on an existing
live CD ISO
self.base_on_iso(base_on)
- self.instloop = LoopbackMount("%s/data/LiveOS/os.img"
%(self.build_dir,),
+ self.instloop = LoopbackMount("%s/data/LiveOS/ext3fs.img"
%(self.build_dir,),
"%s/install_root" %(self.build_dir,))
else:
- self.instloop = SparseExt3LoopbackMount("%s/data/LiveOS/os.img"
+ self.instloop = SparseExt3LoopbackMount("%s/data/LiveOS/ext3fs.img"
%(self.build_dir,),
"%s/install_root"
%(self.build_dir,),
@@ -931,7 +931,7 @@
if ret != 0:
raise InstallationError("mksquashfs exited with error (%d)"
%(ret,))
else:
- shutil.move("%s/data/LiveOS/os.img" %(self.build_dir,),
+ shutil.move("%s/data/LiveOS/ext3fs.img" %(self.build_dir,),
"%s/out/LiveOS/ext3fs.img" %(self.build_dir,))
def _getBlockCountOfExt2FS(self, filesystem):
@@ -981,7 +981,7 @@
# resize2fs-to-uncompressed-size (with implicit resparsification)
#
def cleanupDeleted(self):
- image = "%s/data/LiveOS/os.img" %(self.build_dir,)
+ image = "%s/data/LiveOS/ext3fs.img" %(self.build_dir,)
subprocess.call(["/sbin/e2fsck", "-f", "-y", image])
@@ -1002,8 +1002,8 @@
#
# genMinInstDelta: generates an osmin overlay file to sit alongside
- # os.img. liveinst may then detect the existence of
- # osmin, and use it to create a minimized os.img
+ # ext3fs.img. liveinst may then detect the existence of
+ # osmin, and use it to create a minimized ext3fs.img
# which can be installed more quickly, and to smaller
# destination volumes.
#
@@ -1017,7 +1017,7 @@
os.close(fd)
# associate os image with loop device
- osloop = LoopbackMount("%s/data/LiveOS/os.img" %(self.build_dir,), \
+ osloop = LoopbackMount("%s/data/LiveOS/ext3fs.img" %(self.build_dir,),
\
"None")
osloop.loopsetup()
diff -Naur livecd.4.syslinux_to_boot/creator/mayflower
livecd.5.os_to_ext3fs/creator/mayflower
--- livecd.4.syslinux_to_boot/creator/mayflower 2007-09-21 07:05:02.000000000
+0000
+++ livecd.5.os_to_ext3fs/creator/mayflower 2007-09-21 07:46:02.000000000
+0000
@@ -706,7 +706,7 @@
mount -n -t squashfs -o ro \$SQUASHED_LOOPDEV /squashfs
BASE_LOOPDEV=\$( losetup -f )
- losetup \$BASE_LOOPDEV /squashfs/LiveOS/os.img
+ losetup \$BASE_LOOPDEV /squashfs/LiveOS/ext3fs.img
umount -l /squashfs
if [ "\$live_ram" == "0" ] ; then
Next Message by Thread:
Re: [PATCH 4/7] move syslinux and isolinux directories under /boot
En/na Douglas McClendon ha escrit:
This patch moves the /isolinux directory on the livecd to
/boot/isolinux, and the /syslinux directory on liveusb to /boot/syslinux.
I think that this will be make the livecd appear less intimidating to
new non-linux-guru users. Aesthetics.
Since I don't use ppc myself, I didn't attempt to also move the /ppc dir
to /boot/ppc on the ppc side. But I would recommend that as well if
possible.
-dmc
Why not to put both the isolinux and ppc files directly into the /boot
directory? I don't see the sense of having the /boot directory containig
only a subdirectory. You already know the boot directory holds boot
manager files, and configuration filenames tells you what boot manager
it uses.
Cheers,
Àlex
|
|