VirtualBox

source: vbox/trunk/src/VBox/Devices/PC/Etherboot-src/util/geniso@ 16444

Last change on this file since 16444 was 1, checked in by vboxsync, 55 years ago

import

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 1.1 KB
Line 
1#!/bin/bash
2#
3# Generate a isolinux ISO boot image
4#
5# geniso foo.iso foo.zlilo
6#
7# the ISO image is the first argument so that a list of .zlilo images
8# to include can be specified
9#
10case $# in
110|1)
12 echo Usage: $0 foo.iso foo.zlilo ...
13 exit 1
14 ;;
15esac
16# This should be the default location of the isolinux.bin file
17isolinux_bin=${ISOLINUX_BIN:-util/isolinux.bin}
18if [ ! -r $isolinux_bin ]
19then
20 echo $0: $isolinux_bin not found, please install, or set ISOLINUX_BIN in arch/i386/Config correctly
21 exit 1
22fi
23out=$1
24shift
25dir=bin/iso.dir
26mkdir -p $dir
27cfg=$dir/isolinux.cfg
28cp -p $isolinux_bin $dir
29cat > $cfg <<EOF
30# These default options can be changed in the geniso script
31SAY Etherboot ISO boot image generated by geniso
32TIMEOUT 30
33EOF
34first=
35for f
36do
37 if [ ! -r $f ]
38 then
39 echo $f does not exist, skipping 1>&2
40 continue
41 fi
42 b=$(basename $f)
43 g=${b%.zlilo}
44 g=${g//[^a-z0-9]}.zli
45 case "$first" in
46 "")
47 echo DEFAULT $g
48 ;;
49 esac
50 first=$g
51 echo LABEL $b
52 echo "" KERNEL $g
53 cp -p $f $dir/$g
54done >> $cfg
55mkisofs -l -o $out -c boot.cat -b isolinux.bin -no-emul-boot -boot-load-size 4 -boot-info-table $dir
56rm -fr $dir
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette