summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorJeremy Katz <katzj@redhat.com>2004-04-06 22:39:01 +0000
committerJeremy Katz <katzj@redhat.com>2004-04-06 22:39:01 +0000
commit5dab532b10a7d1cd45aac0e75874caffb62b2240 (patch)
tree84dcd1cb7ec0fa4938bf1b16e79e91ed8827806c /scripts
parent724c8db86c39536b6c84eb5b1a845d5be5bae4c5 (diff)
downloadanaconda-5dab532b10a7d1cd45aac0e75874caffb62b2240.tar.gz
anaconda-5dab532b10a7d1cd45aac0e75874caffb62b2240.tar.xz
anaconda-5dab532b10a7d1cd45aac0e75874caffb62b2240.zip
add a bootable image for usb pendrives (boot.img)
Diffstat (limited to 'scripts')
-rw-r--r--scripts/mk-images.i38616
-rw-r--r--scripts/mk-images.x86_6411
2 files changed, 27 insertions, 0 deletions
diff --git a/scripts/mk-images.i386 b/scripts/mk-images.i386
index b4488f5c3..d2d4255b0 100644
--- a/scripts/mk-images.i386
+++ b/scripts/mk-images.i386
@@ -48,6 +48,11 @@ CD-ROM's boot speed would be an advantage.
To use this image file, burn the file onto CD-R (or CD-RW) media as you
normally would.
+
+The boot.img file is a VFAT filesystem image that can be written to a
+USB pendrive or other bootable media larger than a floppy. Note that
+booting via USB is dependent on your BIOS supporting this. It should
+be written to the device using dd.
EOF
# LATEUSBMODS go in the second stage.
@@ -187,6 +192,17 @@ makeBootImages() {
mkisofs -o $TOPDESTPATH/images/boot.iso -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -R -J -V "$PRODUCT" -T $TOPDESTPATH/images/isopath
rm -rf $TOPDESTPATH/images/isopath
+ # now make a boot pendrive image
+ mkdir -p $TOPDESTPATH/images/fobpath
+ dd if=/dev/zero of=$TOPDESTPATH/images/boot.img bs=1M count=6 2>/dev/null
+ mkdosfs -r 16 -C $TOPDESTPATH/images/boot.img
+ $SYSLINUX $TOPDESTPATH/images/boot.img
+ mount %TOPDESTPATH/images/boot.img $TOPDESTPATH/images/fobpath
+ cp -rl $TOPDESTPATH/isolinux $TOPDESTPATH/images/fobpath
+ mv $TOPDESTPATH/images/fobpath/isolinux.cfg $TOPDESTPATH/images/fobpath/syslinux.cfg
+ umount -f $TOPDESTPATH/images/fobpath
+ rmdir $TOPDESTPATH/images/fobpath
+
cat > $TOPDESTPATH/images/pxeboot/README <<EOF
The files in this directory are useful for booting a machine via PXE.
diff --git a/scripts/mk-images.x86_64 b/scripts/mk-images.x86_64
index 26813ce28..11ba917f1 100644
--- a/scripts/mk-images.x86_64
+++ b/scripts/mk-images.x86_64
@@ -115,6 +115,17 @@ makeBootImages() {
cp -rl $TOPDESTPATH/isolinux $TOPDESTPATH/images/isopath
mkisofs -o $TOPDESTPATH/images/boot.iso -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -R -J -V "$PRODUCT" -T $TOPDESTPATH/images/isopath
rm -rf $TOPDESTPATH/images/isopath
+
+ # now make a boot pendrive image
+ mkdir -p $TOPDESTPATH/images/fobpath
+ dd if=/dev/zero of=$TOPDESTPATH/images/boot.img bs=1M count=6 2>/dev/null
+ mkdosfs -r 16 -C $TOPDESTPATH/images/boot.img
+ $SYSLINUX $TOPDESTPATH/images/boot.img
+ mount %TOPDESTPATH/images/boot.img $TOPDESTPATH/images/fobpath
+ cp -rl $TOPDESTPATH/isolinux $TOPDESTPATH/images/fobpath
+ mv $TOPDESTPATH/images/fobpath/isolinux.cfg $TOPDESTPATH/images/fobpath/syslinux.cfg
+ umount -f $TOPDESTPATH/images/fobpath
+ rmdir $TOPDESTPATH/images/fobpath
}
makeSecondStage() {