Last change
on this file since 10390 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 | #
|
---|
10 | case $# in
|
---|
11 | 0|1)
|
---|
12 | echo Usage: $0 foo.iso foo.zlilo ...
|
---|
13 | exit 1
|
---|
14 | ;;
|
---|
15 | esac
|
---|
16 | # This should be the default location of the isolinux.bin file
|
---|
17 | isolinux_bin=${ISOLINUX_BIN:-util/isolinux.bin}
|
---|
18 | if [ ! -r $isolinux_bin ]
|
---|
19 | then
|
---|
20 | echo $0: $isolinux_bin not found, please install, or set ISOLINUX_BIN in arch/i386/Config correctly
|
---|
21 | exit 1
|
---|
22 | fi
|
---|
23 | out=$1
|
---|
24 | shift
|
---|
25 | dir=bin/iso.dir
|
---|
26 | mkdir -p $dir
|
---|
27 | cfg=$dir/isolinux.cfg
|
---|
28 | cp -p $isolinux_bin $dir
|
---|
29 | cat > $cfg <<EOF
|
---|
30 | # These default options can be changed in the geniso script
|
---|
31 | SAY Etherboot ISO boot image generated by geniso
|
---|
32 | TIMEOUT 30
|
---|
33 | EOF
|
---|
34 | first=
|
---|
35 | for f
|
---|
36 | do
|
---|
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
|
---|
54 | done >> $cfg
|
---|
55 | mkisofs -l -o $out -c boot.cat -b isolinux.bin -no-emul-boot -boot-load-size 4 -boot-info-table $dir
|
---|
56 | rm -fr $dir
|
---|
Note:
See
TracBrowser
for help on using the repository browser.