1<HTML>
2<HEAD>
3<TITLE>MKHYBRID</TITLE>
4</HEAD>
5<BODY BGCOLOR="#FFFFFF">
6<CENTER><H1>MKHYBRID</H1></CENTER>
7<HR>
8<PRE>
9
10</PRE>
11<A NAME="NAME"><H2>NAME</H2></A><PRE>
12       mkhybrid  - create an hybrid ISO9660/JOLIET/HFS filesystem
13       with optional Rock Ridge attributes.
14
15
16</PRE>
17<A NAME="SYNOPSIS"><H2>SYNOPSIS</H2></A><PRE>
18       <STRONG>mkhybrid</STRONG> [ <STRONG>-a</STRONG> ] [ <STRONG>-abstract</STRONG> <EM>FILE</EM> ] [ <STRONG>-biblio</STRONG> <EM>FILE</EM> ]  [  <STRONG>-b</STRONG>
19       <EM>boot</EM><STRONG>_</STRONG><EM>image</EM>  ] [ <STRONG>-c</STRONG> <EM>boot</EM><STRONG>_</STRONG><EM>catalog</EM> ] [ <STRONG>-copyright</STRONG> <EM>FILE</EM> ] [ <STRONG>-A</STRONG>
20       <EM>application</EM><STRONG>_</STRONG><EM>id</EM> ] [ <STRONG>-f</STRONG> ] [ <STRONG>-d</STRONG> ] [ <STRONG>-D</STRONG> ] [  <STRONG>-hide</STRONG>  <EM>glob</EM>  ]  [
21       <STRONG>-hide-list</STRONG>  <EM>file</EM>  ]  [ <STRONG>-hide-joliet</STRONG> <EM>glob</EM> ] [ <STRONG>-hide-joliet-</STRONG>
22       <STRONG>list</STRONG> <EM>file</EM> ] [ <STRONG>-J</STRONG> ] [ <STRONG>-l</STRONG> ] [ <STRONG>-L</STRONG> ] [ <STRONG>-log-file</STRONG> <EM>log</EM><STRONG>_</STRONG><EM>file</EM> ]  [
23       <STRONG>-no-split-symlink-components</STRONG>  ] [ <STRONG>-no-split-symlink-fields</STRONG>
24       ] [ <STRONG>-path-list</STRONG> <EM>file</EM> ] [ <STRONG>-p</STRONG> <EM>preparer</EM> ] [ <STRONG>-print-size</STRONG> ] [ <STRONG>-P</STRONG>
25       <EM>publisher</EM>  ] [ <STRONG>-quiet</STRONG> ] [ <STRONG>-r</STRONG> ] [ <STRONG>-R</STRONG> ] [ <STRONG>-sysid</STRONG> <EM>ID</EM> ] [ <STRONG>-T</STRONG> |
26       <STRONG>-table-name</STRONG> <EM>TABLE</EM><STRONG>_</STRONG><EM>NAME</EM> ] [ <STRONG>-v</STRONG> ] [ <STRONG>-V</STRONG> <EM>volid</EM> ] [ <STRONG>-volset</STRONG>  <EM>ID</EM>
27       ]  [ <STRONG>-volset-size</STRONG> <EM>#</EM> ] [ <STRONG>-volset-seqno</STRONG> <EM>#</EM> ] [ <STRONG>-x</STRONG> <EM>path</EM> ] [ <STRONG>-z</STRONG>
28       ] [ <STRONG>-m</STRONG> <EM>glob</EM> ] [ <STRONG>-hfs</STRONG> | <STRONG>-apple</STRONG> ] [ <STRONG>-map</STRONG>  <EM>mapping</EM><STRONG>_</STRONG><EM>file</EM>  ]  [
29       <STRONG>-magic</STRONG>  <EM>magic</EM><STRONG>_</STRONG><EM>file</EM>  ]  [ <STRONG>-no-mac-files</STRONG> ] [ <STRONG>-probe</STRONG> ] [ <STRONG>-no-</STRONG>
30       <STRONG>desktop</STRONG> ] [ <STRONG>-mac-name</STRONG> ]  [  <STRONG>-boot-hfs-file</STRONG>  <EM>driver</EM><STRONG>_</STRONG><EM>file</EM>  [
31       <STRONG>-part</STRONG>  ] [ <STRONG>-auto</STRONG> <EM>AutoStart</EM><STRONG>_</STRONG><EM>file</EM> ] [ <STRONG>-cluster-size</STRONG> <EM>size</EM> ] [
32       <STRONG>-hide-hfs</STRONG> <EM>glob</EM> ] [  <STRONG>-hide-hfs-list</STRONG>  <EM>file</EM>  ]  [  <STRONG>-hfs-volid</STRONG>
33       <EM>hfs</EM><STRONG>_</STRONG><EM>volid</EM>  ]  [  <STRONG>--cap</STRONG>  ]  [  <STRONG>--netatalk</STRONG>  ] [ <STRONG>--double</STRONG> ] [
34       <STRONG>--ethershare</STRONG> ] [ <STRONG>--ushare</STRONG> ] [ <STRONG>--exchange</STRONG> ]  [  <STRONG>--sgi</STRONG>  ]  [
35       <STRONG>--xinet</STRONG>  ]  [ <STRONG>--macbin</STRONG> ] [ <STRONG>--single</STRONG> ] <STRONG>-o</STRONG> <EM>filename</EM> <EM>pathspec</EM>
36       <EM>[pathspec]</EM>
37
38
39</PRE>
40<A NAME="DESCRIPTION"><H2>DESCRIPTION</H2></A><PRE>
41       <STRONG>mkhybrid</STRONG> is effectively a pre-mastering program to  gener-
42       ate  an  HFS/ISO9660/JOLIET hybrid filesystem. It is based
43       on <STRONG>mkisofs</STRONG>(1) and will generate a pure ISO9660  filesystem
44       unless the HFS hybrid command line options are given.
45
46       <STRONG>mkhybrid</STRONG>  can  generate  a  <EM>true</EM>  (or  <EM>shared)</EM>  HFS hybrid
47       filesystem. The same files are  seen  as  HFS  files  when
48       accessed  from  a  Macintosh  and  as  ISO9660  files when
49       accessed from other machines. HFS stands for  <EM>Hierarchical</EM>
50       <EM>File</EM>  <EM>System</EM>  and is the native file system used on Macin-
51       tosh computers.
52
53       As an alternative, <STRONG>mkhybrid</STRONG> can generate the <EM>Apple</EM>  <EM>Enten-</EM>
54       <EM>sions</EM>  <EM>to</EM>  <EM>ISO9660</EM> for each file. These extensions provide
55       each file with CREATOR, TYPE and certain Finder Flags when
56       accessed  from a Macintosh. See the <STRONG>MACINTOSH</STRONG> <STRONG>FILE</STRONG> <STRONG>FORMATS</STRONG>
57       section below.
58
59       <STRONG>mkhybrid</STRONG> takes a snapshot of a given directory  tree,  and
60       generates  a  binary  image  which  will  correspond to an
61       ISO9660 or HFS filesystem when written to a block  device.
62
63       <STRONG>mkhybrid</STRONG>  is  also  capable  of  generating the System Use
64       Sharing Protocol  records  specified  by  the  Rock  Ridge
65       Interchange  Protocol.   This  is used to further describe
66       the files in the iso9660 filesystem to a  unix  host,  and
67       provides  information  such  as longer filenames, uid/gid,
68       posix permissions, and block and character devices.
69       Each file written to the iso9660 filesystem  must  have  a
70       filename  in the 8.3 format (8 characters, period, 3 char-
71       acters, all upper case), even if Rock  Ridge  is  in  use.
72       This filename is used on systems that are not able to make
73       use of the Rock Ridge extensions  (such  as  MS-DOS),  and
74       each filename in each directory must be different from the
75       other filenames in the same directory.  <STRONG>mkhybrid</STRONG> generally
76       tries  to  form correct names by forcing the unix filename
77       to upper case and truncating as required, but often  times
78       this  yields  unsatisfactory  results when there are cases
79       where the truncated names are not  all  unique.   <STRONG>mkhybrid</STRONG>
80       assigns weightings to each filename, and if two names that
81       are otherwise the same are found the name with  the  lower
82       priority  is renamed to have a 3 digit number as an exten-
83       sion (where the number is guaranteed to  be  unique).   An
84       example of this would be the files foo.bar and foo.bar.~1~
85       - the file foo.bar.~1~ would be written as  FOO.000;1  and
86       the file foo.bar would be written as FOO.BAR;1
87
88       When  used  with the HFS options, <STRONG>mkhybrid</STRONG> will attempt to
89       recognise files stored in a number of Apple/Unix file for-
90       mats  and will copy the data and resource forks as well as
91       any relevant finder information. See  the  <STRONG>MACINTOSH</STRONG>  <STRONG>FILE</STRONG>
92       <STRONG>FORMATS</STRONG> section below for more about formats <STRONG>mkhybrid</STRONG> sup-
93       ports.
94
95       Note that <STRONG>mkhybrid</STRONG> is not designed to communicate with the
96       writer  directly.   Most  writers have proprietary command
97       sets which vary from one manufacturer to another, and  you
98       need  a  specialized  tool to actually burn the disk.  The
99       <STRONG>cdwrite</STRONG> utility is one such tool that runs under Linux and
100       performs  this  task.   The  latest  version of <STRONG>cdwrite</STRONG> is
101       capable of communicating with Phillips/IMS/Kodak,  HP  and
102       Yamaha drives.  Most writers come with some version of DOS
103       software that allows a direct image  copy  of  an  iso9660
104       image  to  the  writer.  The current version of <STRONG>cdwrite</STRONG> is
105       available  from   <STRONG><A HREF="ftp://sunsite.unc.edu/utils/disk-management/cdwrite-2.0.tar.gz">ftp://sunsite.unc.edu/utils/disk-manage-</A></STRONG>
106       <STRONG><A HREF="ftp://sunsite.unc.edu/utils/disk-management/cdwrite-2.0.tar.gz">ment/cdwrite-2.0.tar.gz</A></STRONG>  Note  that  cdwrite  has not been
107       actively maintained in recent times.
108
109       The <STRONG>cdrecord</STRONG> utility is another utility capable of burning
110       an  actual disc.  The latest version of <STRONG>cdrecord</STRONG> is avail-
111       able     from     <STRONG><A HREF="ftp://ftp.fokus.gmd.de/pub/unix/cdrecord">ftp://ftp.fokus.gmd.de/pub/unix/cdrecord</A></STRONG>
112       Cdrecord is under constant development.
113
114       Also you should know that most cd writers are very partic-
115       ular about timing.  Once you start to  burn  a  disc,  you
116       cannot  let their buffer empty before you are done, or you
117       will end up with a corrupt disc.  Thus it is critical that
118       you  be  able  to maintain an uninterrupted data stream to
119       the writer for the entire time  that  the  disc  is  being
120       written.
121
122       <EM>pathspec</EM>  is  the  path of the directory tree to be copied
123       into the iso9660 filesystem.  Multiple paths can be speci-
124       fied,  and  <STRONG>mkhybrid</STRONG>  will merge the files found in all of
125       the specified path components to form the cdrom image.
126
127       It is possible to graft the paths at points other than the
128       root  directory,  and  it  is  possible  to graft files or
129       directories onto the cdrom image with names different than
130       what  they have in the source filesystem.  This is easiest
131       to illustrate with a couple of examples.   Let's start  by
132       assuming that a local file ../old.lis exists, and you wish
133       to include it in the cdrom image.
134
135
136            foo/bar/=../old.lis
137
138       will include the  file  old.lis  in  the  cdrom  image  at
139       /foo/bar/old.lis, while
140
141            foo/bar/xxx=../old.lis
142
143       will  include  the  file  old.lis  in  the  cdrom image at
144       /foo/bar/xxx.  The same sort of syntax can  be  used  with
145       directories as well.  <STRONG>mkhybrid</STRONG> will create any directories
146       required such that the graft points  exist  on  the  cdrom
147       image  -  the  directories do not need to appear in one of
148       the paths.  Any directories that are created  on  the  fly
149       like  this  will  have  permissions  0555 and appear to be
150       owned by the person running mkhybrid.  If you  wish  other
151       permissions or owners of the intermediate directories, the
152       easiest solution is to create real directories in the path
153       such that mkhybrid doesn't have to invent them.
154
155       <EM>mkhybrid</EM> will also run on Win9X/NT4 machines when compiled
156       with  Cygnus'  cygwin   (available   from   <STRONG><A HREF="http://sourceware.cygnus.com/cygwin/">http://source-</A></STRONG>
157       <STRONG><A HREF="http://sourceware.cygnus.com/cygwin/">ware.cygnus.com/cygwin/</A></STRONG>).  Therefore  most  references  in
158       this man page to <EM>Unix</EM> can be replaced with <EM>Win32</EM>.
159
160
161
162</PRE>
163<A NAME="OPTIONS"><H2>OPTIONS</H2></A><PRE>
164       <STRONG>-a</STRONG>     Include all files on the iso9660 filesystem.   Nor-
165              mally  files that contain the characters '~' or '#'
166              will not be included (these  are  typically  backup
167              files for editors under unix).
168
169       <STRONG>-abstract</STRONG> <EM>FILE</EM>
170              Specifies  the  abstract file name.  This parameter
171              can  also  be  set  in  the  file  <STRONG>.mkisofsrc</STRONG>  with
172              ABST=filename.   If  specified  in both places, the
173              command line version is used.
174
175       <STRONG>-A</STRONG> <EM>application</EM><STRONG>_</STRONG><EM>id</EM>
176              Specifies a text string that will be  written  into
177              the volume header.  This should describe the appli-
178              cation that will be on the disc.  There is space on
179              the  disc  for 128 characters of information.  This
180              parameter can also be set in  the  file  <EM>.mkisofsrc</EM>
181              with  APPI=id.   If  specified  in both places, the
182              command line version is used.
183
184       <STRONG>-biblio</STRONG> <EM>FILE</EM>
185              Specifies the bibliographic file name.  This param-
186              eter  can  also  be set in the file <STRONG>.mkisofsrc</STRONG> with
187              BIBLO=filename.  If specified in both  places,  the
188              command line version is used.
189
190       <STRONG>-b</STRONG> <EM>boot</EM><STRONG>_</STRONG><EM>image</EM>
191              Specifies  the  path and filename of the boot image
192              to be used when making an "El Torito" bootable  CD.
193              The  pathname  must  be relative to the source path
194              specified to <STRONG>mkhybrid</STRONG>.  This option is required  to
195              make a bootable CD.  The boot image must be exactly
196              the size of one of a 1.2, 1.44, or 2.88 MB  floppy,
197              or  of a 2 KB CD sector, and <STRONG>mkhybrid</STRONG> will use this
198              size when creating the output  iso9660  filesystem.
199              If  the boot file is 2 KB long, a no-emulation boot
200              CD will be created, and the whole 2 KB will be read
201              on  boot.  If the boot file is a floppy image, then
202              only the first 512-byte sector will  be  read  from
203              the  boot  image  (it  is emulating a normal floppy
204              drive).  This will work, for example, if  the  boot
205              image is a LILO-based boot floppy.
206
207       <STRONG>-C</STRONG> <EM>last</EM><STRONG>_</STRONG><EM>sess</EM><STRONG>_</STRONG><EM>start,next</EM><STRONG>_</STRONG><EM>sess</EM><STRONG>_</STRONG><EM>start</EM>
208              This option is needed when <STRONG>mkisofs</STRONG> is used to  cre-
209              ate the image of a second session or a higher level
210              session for a multi session disk.   The  option  <STRONG>-C</STRONG>
211              takes  a  pair of two numbers separated by a comma.
212              The first number is the sector number of the  first
213              sector  in the last session of the disk that should
214              be appended to.  The second number is the  starting
215              sector  number  of  the  new session.  The expected
216              pair  of  numbers  may  be  retrieved  by   calling
217              <STRONG>cdrecord</STRONG>  <STRONG>-msinfo</STRONG>  <STRONG>...</STRONG>   the  <STRONG>-C</STRONG> option may only be
218              uses in conjunction with the <STRONG>-M</STRONG> option.
219
220       <STRONG>-c</STRONG> <EM>boot</EM><STRONG>_</STRONG><EM>catalog</EM>
221              Specifies the path and filename of the boot catalog
222              to  be used when making an "El Torito" bootable CD.
223              The pathname must be relative to  the  source  path
224              specified  to <STRONG>mkhybrid.</STRONG>  This option is required to
225              make a bootable CD.  This file will be  created  by
226              <STRONG>mkhybrid</STRONG>  in  the source filesystem, so be sure the
227              specified filename does not conflict with an exist-
228              ing  file,  as it will be quietly overwritten! Usu-
229              ally a name like "boot.catalog" is chosen.
230
231       <STRONG>-copyright</STRONG> <EM>FILE</EM>
232              Specifies the Copyright file name.  This  parameter
233              can  also  be  set  in  the  file  <STRONG>.mkisofsrc</STRONG>  with
234              COPY=filename.  If specified in  both  places,  the
235              command line version is used.
236
237       <STRONG>-d</STRONG>     Omit  trailing period from files that do not have a
238              period.  This violates the ISO9660 standard, but it
239              happens to work on many systems.  Use with caution.
240
241       <STRONG>-D</STRONG>     Do not use deep directory relocation,  and  instead
242              just  pack  them in the way we see them.  This vio-
243              lates the ISO9660 standard, but it  works  on  many
244              systems.  Use with caution.
245
246       <STRONG>-f</STRONG>     Follow  symbolic links when generating the filesys-
247              tem.  When this option  is  not  in  use,  symbolic
248              links  will be entered using Rock Ridge if enabled,
249              otherwise the file will be ignored.
250
251       <STRONG>-hide</STRONG> <EM>glob</EM>
252              Hide <EM>glob</EM> from being seen on the  ISO9660  or  Rock
253              Ridge  directory.   <EM>glob</EM> is a shell wild-card-style
254              pattern that must match any part of the filename or
255              path.   Multiple  globs may be hidden (up to 1000).
256              If <EM>glob</EM> matches a directory, then the  contents  of
257              that  directory  will  be  hidden.   All the hidden
258              files will still be written to the output CD  image
259              file.  Should be used with the <EM>-hide-joliet</EM> option.
260
261       <STRONG>-hide-list</STRONG> <EM>file</EM>
262              A file containing a list of <EM>globs</EM> to be  hidden  as
263              above.
264
265       <STRONG>-hide-joliet</STRONG> <EM>glob</EM>
266              Hide  <EM>glob</EM> from being seen on the Joliet directory.
267              <EM>glob</EM> is a shell wild-card-style pattern  that  must
268              match  any  part of the filename or path.  Multiple
269              globs may be hidden (up to 1000).  If <EM>glob</EM>  matches
270              a  directory,  then  the contents of that directory
271              will be hidden.  All the hidden files will still be
272              written  to  the  output  CD image file.  Should be
273              used with the <EM>-hide</EM> option.
274
275       <STRONG>-hide-joliet-list</STRONG> <EM>file</EM>
276              A file containing a list of <EM>globs</EM> to be  hidden  as
277              above.
278
279       <STRONG>-l</STRONG>     Allow  full  32  character filenames.  Normally the
280              ISO9660 filename will be in an 8.3 format which  is
281              compatible  with  MS-DOS,  even  though the ISO9660
282              standard allows filenames of up to  32  characters.
283              If  you  use this option, the disc may be difficult
284              to use on a MS-DOS system, but this comes in  handy
285              on  some  other  systems  (such as the Amiga).  Use
286              with caution.
287
288       <STRONG>-J</STRONG>     Generate Joliet directory records  in  addition  to
289              regular iso9660 file names.  This is primarily use-
290              ful when the discs are to be used on Windows-NT  or
291              Windows-95  machines.    The  Joliet  filenames are
292              specified in Unicode and each path component can be
293              up to 64 Unicode characters long.
294
295       <STRONG>-L</STRONG>     Allow filenames to begin with a period.  Usually, a
296              leading dot is replaced with an underscore in order
297              to maintain MS-DOS compatibility.
298
299       <STRONG>-log-file</STRONG> <EM>log</EM><STRONG>_</STRONG><EM>file</EM>
300              Redirect  all error, warning and informational mes-
301              sages to <EM>log</EM><STRONG>_</STRONG><EM>file</EM> instead of the standard error.
302
303       <STRONG>-m</STRONG> <EM>glob</EM>
304              Exclude <EM>glob</EM> from being written to CDROM.  <EM>glob</EM>  is
305              a  shell  wild-card-style  pattern  that must match
306              part of the filename (not the path as  with  option
307              <STRONG>-x</STRONG>).   Technically  <EM>glob</EM>  is  matched  against  the
308              <EM>d-&gt;d</EM><STRONG>_</STRONG><EM>name</EM> part of the  directory  entry.   Multiple
309              globs may be excluded (up to 1000).  Example:
310
311              mkhybrid -o rom -m '*.o' -m core -m foobar
312
313              would  exclude  all  files  ending  in ".o", called
314              "core" or "foobar" to be copied to CDROM. Note that
315              if  you had a directory called "foobar" it too (and
316              of course all its descendants) would be excluded.
317
318              NOTE: The -m and -x option description should  both
319              be  updated, they are wrong.  Both now work identi-
320              cal and use filename globbing. A file is exluded if
321              either the last component matches or the whole path
322              matches.
323
324       <STRONG>-exclude-list</STRONG> <EM>file</EM>
325              A file containing a list of <EM>globs</EM> to be exclude  as
326              above.
327
328       <STRONG>-M</STRONG> <EM>path</EM>
329              or
330
331       <STRONG>-M</STRONG> <EM>device</EM>
332              Specifies  path  to  existing  iso9660  image to be
333              merged. The alternate  form  takes  a  SCSI  device
334              specifier  that  uses  the  same syntax as the <STRONG>dev=</STRONG>
335              parameter of <STRONG>cdrecord.</STRONG>  The output of <STRONG>mkhybrid</STRONG> will
336              be  a  new  session which should get written to the
337              end of the image specified in -M.   Typically  this
338              requires  multi-session capability for the recorder
339              and cdrom drive that you are  attempting  to  write
340              this  image  to.   This  option may only be used in
341              conjunction with the <STRONG>-C</STRONG> option.
342
343       <STRONG>-N</STRONG>     Omit version numbers from ISO9660 file names.  This
344              may violate the ISO9660 standard, but no one really
345              uses the version numbers anyway.  Use with caution.
346
347       <STRONG>-no-split-symlink-components</STRONG>
348              Don't split the SL components, but begin a new Con-
349              tinuation Area (CE) instead. This  may  waste  some
350              space,  but  the SunOS 4.1.4 cdrom driver has a bug
351              in reading split SL components (link_size =  compo-
352              nent_size  instead of link_size += component_size).
353
354       <STRONG>-no-split-symlink-fields</STRONG>
355              Don't split the SL fields, but begin a new Continu-
356              ation Area (CE) instead. This may waste some space,
357              but the SunOS 4.1.4 and Solaris 2.5.1 cdrom  driver
358              have a bug in reading split SL fields (a `/' can be
359              dropped).
360
361       <STRONG>-o</STRONG> <EM>filename</EM>
362              is the name  of  the  file  to  which  the  iso9660
363              filesystem  image should be written.  This can be a
364              disk file, a  tape  drive,  or  it  can  correspond
365              directly  to  the  device  name of the optical disc
366              writer.  If not specified, stdout  is  used.   Note
367              that  the output can also be a block special device
368              for a regular disk drive, in which  case  the  disk
369              partition  can  be  mounted  and examined to ensure
370              that the premastering was done correctly.
371
372       <STRONG>-path-list</STRONG> <EM>file</EM>
373              A file containing a list  of  <EM>filespec</EM>  directories
374              and  filenames  to be added to the ISO9660 filesys-
375              tem. This list of filespecs are processed after any
376              that appear on the command line. If the argument is
377              <EM>-</EM>, then the list is read from the standard input.
378
379       <STRONG>-P</STRONG> <EM>publisher</EM><STRONG>_</STRONG><EM>id</EM>
380              Specifies a text string that will be  written  into
381              the  volume  header.  This should describe the pub-
382              lisher of the CDROM, usually with a mailing address
383              and  phone  number.  There is space on the disc for
384              128 characters of information.  This parameter  can
385              also  be set in the file <EM>.mkisofsrc</EM> with PUBL=.  If
386              specified in both places, the command line  version
387              is used.
388
389       <STRONG>-p</STRONG> <EM>preparer</EM><STRONG>_</STRONG><EM>id</EM>
390              Specifies  a  text string that will be written into
391              the volume header.  This should describe  the  pre-
392              parer  of the CDROM, usually with a mailing address
393              and phone number.  There is space on the  disc  for
394              128  characters of information.  This parameter can
395              also be set in the file <EM>.mkisofsrc</EM> with PREP=.   If
396              specified  in both places, the command line version
397              is used.
398
399       <STRONG>-print-size</STRONG>
400              Print estimated  filesystem  size  and  exit.  This
401              option  is  needed  for  Disk At Once mode and with
402              some  CD-R  drives  when   piping   directly   into
403              <STRONG>cdrecord.</STRONG>   In  this  case it is needed to know the
404              size of the filesystem before  the  actual  CD-cre-
405              ation  is  done.   The option -print-size allows to
406              get this size from a "dry-run"  before  the  CD  is
407              actually written.
408
409       <STRONG>-quiet</STRONG> This makes <STRONG>mkhybrid</STRONG> even less verbose.  No progress
410              output will be provided.
411
412       <STRONG>-R</STRONG>     Generate SUSP and RR records using the  Rock  Ridge
413              protocol  to  further  describe  the  files  on the
414              iso9660 filesystem.
415
416       <STRONG>-r</STRONG>     This is like the -R option, but file ownership  and
417              modes  are  set to more useful values.  The uid and
418              gid are set to zero, because they are usually  only
419              useful  on  the  author's system, and not useful to
420              the client.  All the file read bits are  set  true,
421              so that files and directories are globally readable
422              on the client.  If any execute bit  is  set  for  a
423              file, set all of the execute bits, so that executa-
424              bles are globally executable on the client.  If any
425              search  bit  is set for a directory, set all of the
426              search  bits,  so  that  directories  are  globally
427              searchable  on  the  client.   All  write  bits are
428              cleared, because the CD-Rom will be  mounted  read-
429              only  in any case.  If any of the special mode bits
430              are set, clear them, because  file  locks  are  not
431              useful  on a read-only file system, and set-id bits
432              are not desirable for uid 0 or gid 0.  When used on
433              Win32, the execute bit is set on <EM>all</EM> files.
434
435       <STRONG>-sysid</STRONG> <EM>ID</EM>
436              Specifies  the  system ID.  This parameter can also
437              be set in the file <STRONG>.mkisofsrc</STRONG> with  SYSI=system_id.
438              If  specified in both places, the command line ver-
439              sion is used.
440
441       <STRONG>-T</STRONG>     Generate a file TRANS.TBL in each directory on  the
442              CDROM,  which can be used on non-Rock Ridge capable
443              systems to help establish the correct  file  names.
444              There  is also information present in the file that
445              indicates the major and minor numbers for block and
446              character devices, and each symlink has the name of
447              the link file given.
448
449       <STRONG>-table-name</STRONG> <EM>TABLE</EM><STRONG>_</STRONG><EM>NAME</EM>
450              Alternative  translation  table  file   name   (see
451              above). Implies the <EM>-T</EM> option.
452
453       <STRONG>-V</STRONG> <EM>volid</EM>
454              Specifies  the  volume ID (volume name or label) to
455              be written into the master block.   This  parameter
456              can  also  be  set  in  the  file  <EM>.mkisofsrc</EM>  with
457              VOLI=id.  If specified in both places, the  command
458              line  version  is  used.  Note that if you assign a
459              volume ID, this is the name that will  be  used  as
460              the  mount point used by the Solaris volume manage-
461              ment system and the name that is  assigned  to  the
462              disc on a Windows or Mac platform.
463
464       <STRONG>-volset</STRONG> <EM>ID</EM>
465              Specifies  the  volset ID.  This parameter can also
466              be set in the file <STRONG>.mkisofsrc</STRONG> with  VOLS=volset_id.
467              If  specified in both places, the command line ver-
468              sion is used.
469
470       <STRONG>-volset-size</STRONG> <EM>#</EM>
471              Sets the volume set size to #.  The volume set size
472              is  the  number  of CD's that are in a CD set.  The
473              <STRONG>-volset-size</STRONG> option may be used to create CD's that
474              are  part  of  e.g. a Operation System installation
475              set of CD's.  The option <STRONG>-volset-size</STRONG> must be spec-
476              ified before <STRONG>-volset-seqno</STRONG> on each command line.
477
478       <STRONG>-volset-seqno</STRONG> <EM>#</EM>
479              Sets the volume set sequence number to #.  The vol-
480              ume set sequence number is the index number of  the
481              current  CD  in  a CD set.  The option <STRONG>-volset-size</STRONG>
482              must be specified before <STRONG>-volset-seqno</STRONG> on each com-
483              mand line.
484
485       <STRONG>-v</STRONG>     Verbose  execution.  If  given twice on the command
486              line, extra debug information will be printed.
487
488       <STRONG>-x</STRONG> <EM>path</EM>
489              Exclude <EM>path</EM> from being  written  to  CDROM.   <EM>path</EM>
490              must  be  the  complete  pathname that results from
491              concatenating the pathname given  as  command  line
492              argument  and  the path relative to this directory.
493              Multiple paths may be excluded (up to 1000).  Exam-
494              ple:
495
496              mkhybrid -o cd -x /local/dir1 -x /local/dir2 /local
497
498              NOTE: The -m and -x option description should  both
499              be  updated, they are wrong.  Both now work identi-
500              cal and use filename globbing. A file is exluded if
501              either the last component matches or the whole path
502              matches.
503
504       <STRONG>-z</STRONG>     Generate special  SUSP  records  for  transparently
505              compressed files.  This is only of use and interest
506              for hosts that support  transparent  decompression.
507              This  is  an experimental feature, and no hosts yet
508              support this, but there are ALPHA patches for Linux
509              that can make use of this feature.
510
511
512</PRE>
513<A NAME="HFS_OPTIONS"><H2>HFS OPTIONS</H2></A><PRE>
514       <STRONG>-hfs</STRONG>   Create  an  ISO9660/HFS  hybrid CD. By default, all
515              source files are checked to  attempt  to  recognise
516              files  stored  in  one of the known Apple/Unix file
517              formats.  See the <STRONG>MACINTOSH</STRONG>  <STRONG>FILE</STRONG>  <STRONG>FORMATS</STRONG>  section
518              below for more about these formats
519
520       <STRONG>-apple</STRONG> Create an ISO9660 CD with Apple's extensions. Simi-
521              lar to the  <EM>-hfs</EM>  option,  except  that  the  Apple
522              Extensions to ISO9660 are added instead of creating
523              an HFS hybrid volume.
524
525       <STRONG>-map</STRONG> <EM>mapping</EM><STRONG>_</STRONG><EM>file</EM>
526              Use the <EM>mapping</EM><STRONG>_</STRONG><EM>file</EM> to set the  CREATOR  and  TYPE
527              information  for  a  file  based  on the filename's
528              extension. A filename is mapped only if it  is  not
529              one  of  the  know Apple/Unix file formats. See the
530              <STRONG>CREATOR/TYPE</STRONG> section below.
531
532       <STRONG>-magic</STRONG> <EM>magic</EM><STRONG>_</STRONG><EM>file</EM>
533              The CREATOR and TYPE information is set by using  a
534              file's <EM>magic</EM> <EM>number</EM> (usually the first few bytes of
535              a file). The <EM>magic</EM><STRONG>_</STRONG><EM>file</EM> is only used if a  file  is
536              not  one  of  the known Apple/Unix file formats, or
537              the filename extension has not  been  mapped  using
538              the <EM>-map</EM> option. See the <STRONG>CREATOR/TYPE</STRONG> section below
539              for more details.
540
541       <STRONG>-no-mac-files</STRONG>
542              Disables searching for Apple/Unix files. This  will
543              speed  up processing if there are none of the known
544              Apple/Unix format files  in  the  source  directory
545              trees (the source directories just contain ordinary
546              files). The <EM>-map</EM> and/or <EM>-magic</EM> option can  be  used
547              to set the CREATOR and TYPE for each file.
548
549       <STRONG>-probe</STRONG> Search  the  contents  of files for Apple/Unix file
550              formats. When <EM>-hfs</EM> or <EM>-apple</EM> is used, mkhybrid will
551              attempt  to  work  out  automatically  what type of
552              Apple/Unix format each file is. However,  the  only
553              way to check for <EM>MacBinary</EM> and <EM>AppleSingle</EM> files is
554              to open and read them. Therefore, if  <EM>MacBinary</EM>  or
555              <EM>AppleSingle</EM>  format  files are being used, then you
556              need to give this option.  This saves  opening  and
557              searching   every   file  if  no  <EM>MacBinary</EM>  and/or
558              <EM>AppleSingle</EM> files exist. Or you could use the rele-
559              vant <EM>double</EM> <EM>dash</EM> options given below.
560
561       <STRONG>-no-desktop</STRONG>
562              Do  not  create  (empty)  Desktop  files.  New  HFS
563              Desktop files will be created when the CD  is  used
564              on  a  Macintosh (and stored in the System Folder).
565              By default, empty Desktop files are  added  to  the
566              HFS volume.
567
568       <STRONG>-mac-name</STRONG>
569              Use  the HFS filename as the starting point for the
570              ISO9660, Joliet and Rock Ridge file names. See  the
571              <STRONG>MACINTOSH</STRONG>  <STRONG>FILE</STRONG> <STRONG>NAMES</STRONG> section below for more infor-
572              mation.
573
574       <STRONG>-boot-hfs-file</STRONG> <EM>driver</EM><STRONG>_</STRONG><EM>file</EM>
575              Installs the  <EM>driver</EM><STRONG>_</STRONG><EM>file</EM>  that  <EM>may</EM>  make  the  CD
576              bootable  on  a  Macintosh. See the <STRONG>HFS</STRONG> <STRONG>BOOT</STRONG> <STRONG>DRIVER</STRONG>
577              section below. (Alpha).
578
579       <STRONG>-part</STRONG>  Generate an HFS partition  table.  By  default,  no
580              partition table is generated, but some older Macin-
581              tosh CDROM drivers need an HFS partition  table  on
582              the CDROM to be able to recognize a hybrid CDROM.
583
584       <STRONG>-auto</STRONG> <EM>AutoStart</EM><STRONG>_</STRONG><EM>file</EM>
585              Make  the  HFS  CD  use the QuickTime 2.0 Autostart
586              feature to launch an application or  document.  The
587              given  filename  must  be the name of a document or
588              application located at the top level of the CD. The
589              filename  must be less than 12 characters. (Alpha).
590
591       <STRONG>-cluster-size</STRONG> <EM>size</EM>
592              Set the size in bytes of the cluster or  allocation
593              units  of PC Exchange files. See the <STRONG>MACINTOSH</STRONG> <STRONG>FILE</STRONG>
594              <STRONG>FORMATS</STRONG> section below.
595
596       <STRONG>-hide-hfs</STRONG> <EM>glob</EM>
597              Hide <EM>glob</EM> from the HFS volume. The file  or  direc-
598              tory  will still exist in the ISO9660 and/or Joliet
599              directory.  <EM>glob</EM> is a shell wild-card-style pattern
600              that  must  match any part of the filename Multiple
601              globs may be excluded (up to 1000).  Example:
602
603              mkhybrid -o rom -hfs -hide-hfs '*.o' -hide-hfs foo-
604              bar
605
606              would  exclude  all  files ending in ".o" or called
607              "foobar" from the HFS volume. Note that if you  had
608              a  directory  called "foobar" it too (and of course
609              all its descendants) would be excluded.   The  <EM>glob</EM>
610              can  also  be  a  path  name relative to the source
611              directories given on the command line. Example:
612
613              mkhybrid -o rom -hfs -hide-hfs src/html src
614
615              would exclude just the  file  or  directory  called
616              "html"  from the "src" directory. Any other file or
617              directory called "html" in the  tree  will  not  be
618              excluded.   Should  be  used  with the <EM>-hide</EM> and/or
619              <EM>-hide-joliet</EM> options.
620
621       <STRONG>-hide-hfs-list</STRONG> <EM>file</EM>
622              A file containing a list of <EM>globs</EM> to be  hidden  as
623              above.
624
625       <STRONG>-hfs-volid</STRONG> <EM>hfs</EM><STRONG>_</STRONG><EM>volid</EM>
626              Volume name for the HFS partition. This is the name
627              that is assigned to the disc  on  a  Macintosh  and
628              replaces the <EM>volid</EM> used with the <EM>-V</EM> option
629
630       <STRONG>--cap</STRONG>  Look  for  AUFS CAP Macintosh files. Search for CAP
631              Apple/Unix file formats  only.  Searching  for  the
632              other possible Apple/Unix file formats is disabled,
633              unless other <EM>double</EM> <EM>dash</EM> options are given.
634
635       <STRONG>--netatalk</STRONG>
636              Look for NETATALK Macintosh files
637
638       <STRONG>--double</STRONG>
639              Look for AppleDouble Macintosh files
640
641       <STRONG>--ethershare</STRONG>
642              Look for Helios EtherShare Macintosh files
643
644       <STRONG>--ushare</STRONG>
645              Look for IPT UShare Macintosh files
646
647       <STRONG>--exchange</STRONG>
648              Look for PC Exchange Macintosh files
649
650       <STRONG>--sgi</STRONG>  Look for SGI Macintosh files
651
652       <STRONG>--xinet</STRONG>
653              Look for XINET Macintosh files
654
655       <STRONG>--macbin</STRONG>
656              Look for MacBinary Macintosh files
657
658       <STRONG>--single</STRONG>
659              Look for AppleSingle Macintosh files
660
661
662
663
664</PRE>
665<A NAME="CREATOR_TYPE"><H2>CREATOR/TYPE</H2></A><PRE>
666       A Macintosh file has two  properties  associated  with  it
667       which  define which application created the file, the <EM>CRE-</EM>
668       <EM>ATOR</EM> and what data the file contains, the <EM>TYPE</EM>.  Both  are
669       (exactly)  4  letter strings. Usually this allows a Macin-
670       tosh user to double-click on a file and launch the correct
671       application etc. The CREATOR and TYPE of a particular file
672       can be found by using something like ResEdit (or  similar)
673       on a Macintosh.
674
675       The CREATOR and TYPE information is stored in all the var-
676       ious Apple/Unix encoded files.  For other files it is pos-
677       sible  to  base  the  CREATOR  and  TYPE on the filename's
678       extension using a <EM>mapping</EM> file (the  <EM>-map</EM>  option)  and/or
679       using  the  <EM>magic</EM> <EM>number</EM> (usually a <EM>signature</EM> in the first
680       few bytes) of a file (the <EM>-magic</EM> option).  If  both  these
681       options are given, then their order on the command line is
682       important. If the <EM>-map</EM> option is given first, then a file-
683       name  extension  match  is attempted before a magic number
684       match. However, if the <EM>-magic</EM> option is given first,  then
685       a magic number match is attempted before a filename exten-
686       sion match.
687
688       If a mapping or magic file is not used,  or  no  match  is
689       found  then  the  default CREATOR and TYPE for all regular
690       files can be set by using entries in the <EM>.mkisofsrc</EM>  file,
691       otherwise  the  default  CREATOR  and  TYPE are 'unix' and
692       'TEXT'.
693
694       The format of the <EM>mapping</EM> file is the same <EM>afpfile</EM>  format
695       as  used  by  <EM>aufs</EM>.   This  file  has five columns for the
696       <EM>extension</EM>, <EM>file</EM> <EM>translation</EM>, <EM>CREATOR</EM>,  <EM>TYPE</EM>  and  <EM>Comment</EM>.
697       Lines  starting  with  the '#' character are comment lines
698       and are ignored. An example file would be like:
699
700       # Example filename mapping file
701       #
702       # EXTN   XLate   CREATOR   TYPE     Comment
703       .tif     Raw     '8BIM'    'TIFF'   "Photoshop TIFF image"
704       .hqx     Ascii   'BnHq'    'TEXT'   "BinHex file"
705       .doc     Raw     'MSWD'    'WDBN'   "Word file"
706       .mov     Raw     'TVOD'    'MooV'   "QuickTime Movie"
707       *        Ascii   'ttxt'    'TEXT'   "Text file"
708
709       Where:
710
711              The first column <EM>EXTN</EM>  defines  the  Unix  filename
712              extension to be mapped. The default mapping for any
713              filename extension that doesn't  match  is  defined
714              with the "*" character.
715
716              The  <EM>Xlate</EM> column defines the type of text transla-
717              tion between the Unix  and  Macintosh  file  it  is
718              ignored  by  <EM>mkhybrid,</EM> but is kept to be compatible
719              with <EM>aufs</EM>(1).  Although <EM>mkhybrid</EM> does not alter the
720              contents  of a file, if a binary file has it's TYPE
721              set as 'TEXT', it <EM>may</EM> be read incorrectly on a Mac-
722              intosh.  Therefore  a better choice for the default
723              TYPE may be '????'
724
725              The <EM>CREATOR</EM> and <EM>TYPE</EM> keywords must be 4  characters
726              long and enclosed in single quotes.
727              The comment field is enclosed in double quotes - it
728              is ignored by <EM>mkhybrid</EM>, but is kept to be  compati-
729              ble with <EM>aufs</EM>.
730
731       The  format  of  the <EM>magic</EM> file is almost identical to the
732       <EM>magic</EM>(4) file used by the Linux <EM>file</EM>(1) command - the rou-
733       tines for reading and decoding the <EM>magic</EM> file are based on
734       the Linux <EM>file</EM>(1) command.
735
736       This file has four tab separated columns for the <EM>byte</EM> <EM>off-</EM>
737       <EM>set</EM>,  <EM>type</EM>, <EM>test</EM> and <EM>message</EM>.  Lines starting with the '#'
738       character are comment lines and are  ignored.  An  example
739       file would be like:
740
741       # Example magic file
742       #
743       # off   type      test       message
744       0       string    GIF8       8BIM GIFf  GIF image
745       0       beshort   0xffd8     8BIM JPEG  image data
746       0       string    SIT!       SIT! SIT!  StuffIt Archive
747       0       string    \037\235   LZIV ZIVU  standard unix compress
748       0       string    \037\213   GNUz ZIVU  gzip compressed data
749       0       string    %!         ASPS TEXT  Postscript
750       0       string    \004%!     ASPS TEXT  PC Postscript with a ^D to start
751       4       string    moov       txtt MooV  QuickTime movie file (moov)
752       4       string    mdat       txtt MooV  QuickTime movie file (mdat)
753
754       The  format  of  the file is described in the <EM>magic</EM>(4) man
755       page. The only difference here is that for each  entry  in
756       the magic file, the <EM>message</EM> for the initial offset <STRONG>must</STRONG> be
757       4 characters for the CREATOR followed by 4 characters  for
758       the TYPE - white space is optional between them. Any other
759       characters on this line are ignored.   Continuation  lines
760       (starting  with a '&gt;') are also ignored i.e. only the ini-
761       tial offset lines are used.
762
763       Using the <EM>-magic</EM> option may  significantly  increase  pro-
764       cessing  time  as each file has to opened and read to find
765       it's magic number.
766
767       In summary, for all files, the default CREATOR  is  'unix'
768       and  the  default TYPE is 'TEXT'.  These can be changed by
769       using entries in the <EM>.mkisofsrc</EM> file.
770
771       If the a file is in one of the  known  Apple/Unix  formats
772       (and  the  format has been selected), then the CREATOR and
773       TYPE are taken from the values stored  in  the  Apple/Unix
774       file.
775
776       Other files can have their CREATOR and TYPE set from their
777       file name extension (the <EM>-map</EM> option), or their magic num-
778       ber  (the  <EM>-magic</EM> option). If the default match is used in
779       the <EM>mapping</EM> file, then these values override  the  default
780       CREATOR and TYPE.
781       A   full   CREATOR/TYPE   database   can   be   found   at
782       <STRONG><A HREF="http://www.angelfire.com/il/szekely/index.html">http://www.angelfire.com/il/szekely/index.html</A></STRONG>
783
784
785
786</PRE>
787<A NAME="MACINTOSH_FILE_FORMATS"><H2>MACINTOSH FILE FORMATS</H2></A><PRE>
788       Macintosh  files  have  two  parts  called  the  <EM>Data</EM>  and
789       <EM>Resource</EM>  fork.  Either may be empty. Unix (and many other
790       OSs) can only cope with files having one part  (or  fork).
791       To   add  to  this,  Macintosh  files  have  a  number  of
792       attributes associated with them - probably the most impor-
793       tant  are  the TYPE and CREATOR. Again Unix has no concept
794       of these types of attributes.
795
796       e.g. a Macintosh file may be a JPEG image where the  image
797       is  stored in the Data fork and a desktop thumbnail stored
798       in the Resource fork. It is usually the information in the
799       data fork that is useful across platforms.
800
801       Therefore  to store a Macintosh file on a Unix filesystem,
802       a way has to be found to cope with the two forks  and  the
803       extra  attributes  (which  are  referred  to as the <EM>finder</EM>
804       <EM>info).</EM>  Unfortunately, it seems that every software  pack-
805       age  that stores Macintosh files on Unix has chosen a com-
806       pletely different storage method.
807
808       The Apple/Unix formats that <EM>mkhybrid</EM> (partially)  supports
809       are:
810
811       CAP AUFS format
812              Data fork stored in a file. Resource fork in subdi-
813              rectory .resource with same filename as data  fork.
814              Finder  info  in .finderinfo subdirectory with same
815              filename.
816
817       AppleDouble/Netatalk
818              Data fork stored in a file. Resource fork stored in
819              a  file  with  same  name prefixed with "%". Finder
820              info also stored in same "%"  file.  Netatalk  uses
821              the  same  format, but the resource fork/finderinfo
822              stored in subdirectory .AppleDouble with same  name
823              as data fork.
824
825       AppleSingle
826              Data structures similar to above, except both forks
827              and finder info are stored in one file.
828
829       Helios EtherShare
830              Data fork stored  in  a  file.  Resource  fork  and
831              finder  info  together  in  subdirectory .rsrc with
832              same filename as data fork.
833
834       IPT UShare
835              Very similar to  the  EtherShare  format,  but  the
836              finder info is stored slightly differently.
837
838       MacBinary
839              Both forks and finder info stored in one file.
840
841       Apple PC Exchange
842              Used  by  Macintoshes  to  store Apple files on DOS
843              (FAT) disks.  Data fork stored in a file.  Resource
844              fork     in     subdirectory    resource.frk    (or
845              RESOURCE.FRK). Finder info as one  record  in  file
846              finder.dat (or FINDER.DAT). Separate finder.dat for
847              each data fork directory.
848
849              Note: normally files should  be  accessed  directly
850              from  the  DOS  media as <EM>mkhybrid</EM> needs to find out
851              the native FAT cluster size.   If  the  native  FAT
852              cluster  size  is  known,  then  the  <EM>-cluster-size</EM>
853              option can be used to set the cluster size - useful
854              if  PC Exchange files have be copied from DOS disks
855              before running <EM>mkhybrid</EM>.  The cluster or allocation
856              size  can be found by using the DOS utility <EM>CHKDSK</EM>.
857
858              May not work with PC Exchange v2.2 or higher  files
859              (available  with  MacOS 8.1).  DOS media containing
860              PC Exchange files should be mounted as  type  <STRONG>msdos</STRONG>
861              (not <STRONG>vfat</STRONG>) when using Linux.
862
863       SGI/XINET
864              Used  by  SGI  machines  when they mount HFS disks.
865              Data fork stored in a file. Resource fork in subdi-
866              rectory  .HSResource with same name. Finder info as
867              one record in file .HSancillary. Separate .HSancil-
868              lary for each data fork directory.
869
870       <EM>mkhybrid</EM>  will  attempt to set the CREATOR, TYPE, date and
871       possibly other flags from the finder  info.  Additionally,
872       if  it  exists,  the  Macintosh  filename  is set from the
873       finder info, otherwise the Macintosh name is based on  the
874       Unix  filename  -  see  the  MACINTOSH  FILE NAMES section
875       below.
876
877       When using the <EM>-apple</EM> option, the  TYPE  and  CREATOR  are
878       stored  in  the  optional  System Use or SUSP field in the
879       ISO9660 Directory Record - in much the  same  way  as  the
880       Rock  Ridge attributes are. In fact to make life easy, the
881       Apple extensions are added at the beginning of the  exist-
882       ing  Rock  Ridge  attributes (i.e. to get the Apple exten-
883       sions you get the Rock Ridge extensions as well).
884
885       The Apple extensions  require  the  resource  fork  to  be
886       stored  as  an  ISO9660 <EM>associated</EM> file. This is just like
887       any normal file stored in the  ISO9660  filesystem  except
888       that  the  associated  file  flag  is set in the Directory
889       Record (bit 2). This file has the same name  as  the  data
890       fork  (the  file  seen  by non-Apple machines). Associated
891       files are normally ignored by other OSs
892       When using the <EM>-hfs</EM> option,  the  TYPE  and  CREATOR  plus
893       other finder info, are stored in a separate HFS directory,
894       not visible on the ISO9660 volume. The HFS directory  ref-
895       erences  the  same  data and resource fork files described
896       above.
897
898       In most cases, it is better to use the <EM>-hfs</EM> option instead
899       of  the  <EM>-apple</EM>  option, as the latter imposes the limited
900       ISO9660 characters  allowed  in  filenames.  However,  the
901       Apple  extensions do give the advantage that the files are
902       packed on the disk more efficiently and it may be possible
903       to  fit more files on a CD - important when the total size
904       of the source files is approaching 650MB.
905
906
907
908
909
910</PRE>
911<A NAME="MACINTOSH_FILE_NAMES"><H2>MACINTOSH FILE NAMES</H2></A><PRE>
912       Where possible, the HFS filename that is  stored  with  an
913       Apple/Unix  file  is used for the HFS part of the CD. How-
914       ever, not all the Apple/Unix encodings store the HFS file-
915       name  with  the finderinfo. In these cases, the Unix file-
916       name is used - with escaped  special  characters.  Special
917       characters include '/' and characters with codes over 127.
918
919       Aufs escapes these characters by using ":" followed by the
920       character  code as two hex digits. Netatalk and EtherShare
921       have a similar scheme, but uses "%" instead of a ":".
922
923       If mkhybrid can't find an HFS filename, then it  uses  the
924       Unix  name,  with any %xx or :xx characters (xx == two hex
925       digits) converted to a single character code. If "xx"  are
926       not  hex  digits ([0-9a-fA-F]), then they are left alone -
927       although any remaining ":" is converted to "%" as colon is
928       the  HFS  directory  separator.  Care must be taken, as an
929       ordinary Unix file with %xx or :xx will also be converted.
930       e.g.
931
932       This:2fFile   converted to This/File
933
934       This:File     converted to This%File
935
936       This:t7File   converted to This%t7File
937
938       Although  HFS  filenames appear to support upper and lower
939       case letters, the filesystem is case insensitive. i.e. the
940       filenames "aBc" and "AbC" are the same. If a file is found
941       in a directory with the same HFS name, then <EM>mkhybrid</EM>  will
942       attempt,  where  possible, to make a unique name by adding
943       '_' characters to one of the filenames.
944
945       If an HFS filename exists for a file,  then  mkhybrid  can
946       use  this  name  as  the  starting  point for the ISO9660,
947       Joliet  and  Rock  Ridge  filenames  using  the  <EM>-mac-name</EM>
948       option.  Normal  Unix files without an HFS name will still
949       use their Unix name.  e.g.
950
951       If a <EM>MacBinary</EM> (or <EM>PC</EM> <EM>Exchange</EM>) file is stored as  <EM>someim-</EM>
952       <EM>age.gif.bin</EM>  on  the  Unix  filesystem, but contains a HFS
953       file called <EM>someimage.gif</EM>, then  this  is  the  name  that
954       would  appear on the HFS part of the CD. However, as mkhy-
955       brid uses the Unix name as  the  starting  point  for  the
956       other names, then the ISO9660 name generated will probably
957       be <EM>SOMEIMAG.BIN</EM> and the Joliet/Rock Ridge would be <EM>someim-</EM>
958       <EM>age.gif.bin</EM>.  Although the actual data (in this case) is a
959       GIF image. This option will use the HFS  filename  as  the
960       starting  point  and  the  ISO9660  name  will probably be
961       <EM>SOMEIMAG.GIF</EM> and the Joliet/Rock Ridge  would  be  <EM>someim-</EM>
962       <EM>age.gif</EM>.
963
964       Using  the  <EM>-mac-name</EM>  option will not currently work with
965       the <EM>-T</EM> option  -  the  Unix  name  will  be  used  in  the
966       TRANS.TBL file, not the Macintosh name.
967
968       The  existing  mkisofs  code  will  filter out any illegal
969       characters for the ISO9660 and Joliet  filenames,  but  as
970       mkisofs expects to be dealing directly with Unix names, it
971       leaves the Rock Ridge names as is.  But as '/' is a  legal
972       HFS  filename  character, the <EM>-mac-name</EM> option coverts '/'
973       to a '_' in a Rock Ridge filenames.
974
975       If the Apple extensions are used, then  only  the  ISO9660
976       filenames  will  appear  on the Macintosh. However, as the
977       Macintosh ISO9660 drivers can use <EM>Level</EM> <EM>2</EM> filenames,  then
978       you  can use the <EM>-l</EM> option without problems on a Macintosh
979       -  still  take  care   over   the   names,   for   example
980       <EM>this.file.name</EM>  will  be  converted to <EM>THIS.FILE</EM> i.e. only
981       have one '.', also  filename  <EM>abcdefgh</EM>  will  be  seen  as
982       <EM>ABCDEFGH</EM>  but  <EM>abcdefghi</EM>  will be seen as <EM>ABCDEFGHI.</EM>  i.e.
983       with a '.' at the end - don't know if this is a  Macintosh
984       problem or mkisofs/mkhybrid problem. All filenames will be
985       in uppercase  when  viewed  on  a  Macintosh.  Of  course,
986       DOS/Win3.X  machines will not be able to see Level 2 file-
987       names...
988
989       As Macintosh filenames do use the '~' and  '#'  characters
990       (especially  when using PC Exchange Macintosh files), then
991       the <EM>-a</EM> option should be given.
992
993
994
995</PRE>
996<A NAME="HFS_BOOT_DRIVER"><H2>HFS BOOT DRIVER</H2></A><PRE>
997       It <EM>may</EM> be possible to make the hybrid  CD  bootable  on  a
998       Macintosh.
999
1000       A bootable HFS CD requires an Apple CD-ROM (or compatible)
1001       driver, a bootable HFS partition and the necessary System,
1002       Finder, etc. files.
1003
1004       A driver can be obtained from any other Macintosh bootable
1005       CD-ROM using the <EM>apple</EM><STRONG>_</STRONG><EM>driver</EM> utility. This file can  then
1006       be used with the <EM>-boot-hfs-file</EM> option.
1007
1008       The  HFS partition (i.e. the hybrid disk in our case) must
1009       contain a suitable System Folder, again from  another  CD-
1010       ROM or disk.
1011
1012       For  a  partition  to  be bootable, it must have it's <EM>boot</EM>
1013       <EM>block</EM> set. The boot block is in the first two blocks of  a
1014       partition.  For a non-bootable partition the boot block is
1015       full of zeros. Normally, when a System file is  copied  to
1016       partition  on  a  Macintosh disk, the boot block is filled
1017       with a number of required settings - unfortunately I don't
1018       know  the  full  spec  for the boot block, so I'm guessing
1019       that the following will work OK.
1020
1021       Therefore, the utility <EM>apple</EM><STRONG>_</STRONG><EM>driver</EM> also extracts the boot
1022       block  from  the first HFS partition it finds on the given
1023       CD-ROM and this is used for the HFS partition  created  by
1024       <EM>mkhybrid</EM>.
1025
1026       PLEASE NOTE
1027              By  using  a  driver  from  an Apple CD and copying
1028              Apple software to your CD,  you  become  liable  to
1029              obey  Apple  Computer, Inc. Software License Agree-
1030              ments.
1031
1032
1033
1034
1035</PRE>
1036<A NAME="CONFIGURATION"><H2>CONFIGURATION</H2></A><PRE>
1037       <STRONG>mkhybrid</STRONG> looks for the <EM>.mkisofsrc</EM> file, first in the  cur-
1038       rent working directory, then in the user's home directory,
1039       and then in the directory in which the <STRONG>mkhybrid</STRONG> binary  is
1040       stored.  This file is assumed to contain a series of lines
1041       of the form "TAG=value", and in this way you  can  specify
1042       certain  options.  The case of the tag is not significant.
1043       Some fields in the volume header are not settable  on  the
1044       command  line,  but  can be altered through this facility.
1045       Comments may be placed in this  file,  using  lines  which
1046       start with a hash (#) character.
1047
1048       APPI   The  application  identifier  should  describe  the
1049              application that will be on  the  disc.   There  is
1050              space  on  the  disc for 128 characters of informa-
1051              tion.  May be overridden using the -A command  line
1052              option.
1053
1054       COPY   The copyright information, often the name of a file
1055              on the disc containing the copyright notice.  There
1056              is  space in the disc for 37 characters of informa-
1057              tion.  May be overridden using the <STRONG>-copyright</STRONG>  com-
1058              mand line option.
1059
1060       ABST   The  abstract information, often the name of a file
1061              on the disc containing an abstract.  There is space
1062              in  the disc for 37 characters of information.  May
1063              be overridden  using  the  <STRONG>-abstract</STRONG>  command  line
1064              option.
1065
1066       BIBL   The  bibliographic information, often the name of a
1067              file on the disc containing a bibliography.   There
1068              is  space in the disc for 37 characters of informa-
1069              tion.  May be overridden using the  <STRONG>-bilio</STRONG>  command
1070              line option.
1071
1072       PREP   This  should  describe  the  preparer of the CDROM,
1073              usually with a mailing address  and  phone  number.
1074              There  is  space  on the disc for 128 characters of
1075              information.  May be overridden using the  <STRONG>-p</STRONG>  com-
1076              mand line option.
1077
1078       PUBL   This  should  describe  the publisher of the CDROM,
1079              usually with a mailing address  and  phone  number.
1080              There  is  space  on the disc for 128 characters of
1081              information.  May be overridden using the  <STRONG>-P</STRONG>  com-
1082              mand line option.
1083
1084       SYSI   The  System Identifier.  There is space on the disc
1085              for 32 characters of information.  May be  overrid-
1086              den using the <STRONG>-sysid</STRONG> command line option.
1087
1088       VOLI   The  Volume Identifier.  There is space on the disc
1089              for 32 characters of information.  May be  overrid-
1090              den using the <STRONG>-V</STRONG> command line option.
1091
1092       VOLS   The  Volume  Set  Name.  There is space on the disc
1093              for 278 characters of information.  May be overrid-
1094              den using the <STRONG>-volset</STRONG> command line option.
1095
1096       TYPE   The  default  TYPE  for  Macintosh  files.  Must be
1097              exactly 4 characters.
1098
1099       CREATOR
1100              The default CREATOR for Macintosh  files.  Must  be
1101              exactly 4 characters.
1102
1103       <STRONG>mkhybrid</STRONG>  can  also  be  configured  at  compile time with
1104       defaults  for  many  of  these  fields.   See   the   file
1105       defaults.h.
1106
1107
1108</PRE>
1109<A NAME="AUTHOR"><H2>AUTHOR</H2></A><PRE>
1110       <STRONG>mkisofs</STRONG> is not based on the standard mk*fs tools for unix,
1111       because we must generate a complete  copy of  an  existing
1112       filesystem on a disk in the  iso9660 filesystem.  The name
1113       mkisofs is probably a bit of a misnomer, since it not only
1114       creates  the filesystem, but it also populates it as well.
1115
1116       Eric       Youngdale       &lt;ericy@gnu.ai.mit.edu&gt;       or
1117       &lt;eric@andante.jic.com&gt;  wrote  both  the  Linux  isofs9660
1118       filesystem and the mkisofs utility, and is currently main-
1119       taining  them.   The  copyright for the mkisofs utility is
1120       held by Yggdrasil Computing, Incorporated.
1121
1122       <STRONG>mkhybrid</STRONG> is based on <STRONG>mkisofs</STRONG> and works in exactly the same
1123       way as <STRONG>mkisofs</STRONG> without the HFS options. The change in name
1124       is to signify that it does something extra. If you do  not
1125       need  the  HFS  options,  then  you should really be using
1126       <EM>mkisofs</EM>.
1127
1128       HFS hybrid code Copyright (C) James  Pearson  1997,  1998,
1129       1999
1130       libhfs code Copyright (C) 1996, 1997 Robert Leslie
1131       libfile code Copyright (C) Ian F. Darwin 1986, 1987, 1989,
1132       1990, 1991, 1992, 1994, 1995.
1133
1134
1135
1136
1137</PRE>
1138<A NAME="BUGS"><H2>BUGS</H2></A><PRE>
1139       Any files that have hard links to files not  in  the  tree
1140       being copied to the iso9660 filesystem will have an incor-
1141       rect file reference count.
1142
1143       There may be some other ones.  Please, report them to  the
1144       author.
1145
1146
1147
1148</PRE>
1149<A NAME="HFS_PROBLEMS_LIMITATIONS"><H2>HFS PROBLEMS/LIMITATIONS</H2></A><PRE>
1150       I have had to make several assumptions on how I expect the
1151       modified libhfs routines to work,  however  there  may  be
1152       situations  that  either  I  haven't  thought  of, or come
1153       across when these assumptions  fail.   Therefore  I  can't
1154       guarantee  that mkhybrid will work as expected (although I
1155       haven't had a major problem yet). Most of the HFS features
1156       work  fine,  however, some are not fully tested. These are
1157       marked as <EM>Alpha</EM> above.
1158
1159       Output volume size must be at least 800Kb (libhfs limit  -
1160       shouldn't really be a problem).
1161
1162       Although  HFS  filenames appear to support upper and lower
1163       case letters, the filesystem is case insensitive. i.e. the
1164       filenames "aBc" and "AbC" are the same. If a file is found
1165       in a directory with the same HFS name, then <EM>mkhybrid</EM>  will
1166       attempt,  where  possible, to make a unique name by adding
1167       '_' characters to one of the filenames.
1168
1169       HFS file/directory names that share the first  31  charac-
1170       ters  have  _N'  (N == decimal number) substituted for the
1171       last few characters to generate unique names.
1172
1173       Care must be taken when  "grafting"  Apple/Unix  files  or
1174       directories   (see   above   for  the  method  and  syntax
1175       involved). It is not possible to use a  new  name  for  an
1176       Apple/Unix  encoded  file/directory.  e.g. If a Apple/Unix
1177       encoded file called "oldname" is to added to the CD,  then
1178       you can not use the command line:
1179
1180              mkhybrid -o output.raw -hfs newname=oldname cd_dir
1181
1182       mkhybrid  will be unable to decode "oldname". However, you
1183       can graft Apple/Unix encoded files or directories as  long
1184       as you do not atempt to give them new names as above.
1185
1186       The <EM>-M</EM> option has no real meaning with an HFS volume - and
1187       will probably not work.
1188
1189       Symbolic links (as with all other non-regular  files)  are
1190       not added to the HFS directory.
1191
1192       Hybrid  volumes  may  be  larger than pure ISO9660 volumes
1193       containing the same data.
1194
1195       The resulting hybrid volume can  be  accessed  on  a  Unix
1196       machine  by  using  the  hfsutils  routines.  However,  no
1197       changes should be made to the contents of  the  volume  as
1198       it's not a "real" HFS volume.
1199
1200       Using  the  <EM>-mac-name</EM>  option will not currently work with
1201       the <EM>-T</EM> option  -  the  Unix  name  will  be  used  in  the
1202       TRANS.TBL file, not the Macintosh name.
1203
1204       Although  <EM>mkhybrid</EM>  does not alter the contents of a file,
1205       if a binary file has it's TYPE set as 'TEXT',  it  <EM>may</EM>  be
1206       read incorrectly on a Macintosh. Therefore a better choice
1207       for the default TYPE may be '????'
1208
1209       The <EM>-mac-boot-file</EM> option may not work at all...
1210
1211       The <EM>-a</EM> option should be used at all  times.  It  may  well
1212       become the default in future releases.
1213
1214       May not work with PC Exchange v2.2 or higher files (avail-
1215       able with MacOS 8.1).  DOS media  containing  PC  Exchange
1216       files  should  be  mounted  as  type <STRONG>msdos</STRONG> (not <STRONG>vfat</STRONG>) when
1217       using Linux.
1218
1219
1220
1221</PRE>
1222<A NAME="SEE_ALSO"><H2>SEE ALSO</H2></A><PRE>
1223       <EM>mkisofs</EM>(8), <EM>magic</EM>(5), <EM>apple</EM><STRONG>_</STRONG><EM>driver</EM>(8)
1224
1225
1226</PRE>
1227<A NAME="FUTURE_IMPROVEMENTS"><H2>FUTURE IMPROVEMENTS</H2></A><PRE>
1228       Some sort of gui interface.
1229
1230
1231</PRE>
1232<A NAME="AVAILABILITY"><H2>AVAILABILITY</H2></A><PRE>
1233       <STRONG>mkisofs</STRONG>   is   available   for    anonymous    ftp    from
1234       <STRONG><A HREF="ftp://tsx-11.mit.edu/pub/linux/packages/mkisofs">ftp://tsx-11.mit.edu/pub/linux/packages/mkisofs</A></STRONG>  and  many
1235       other mirror sites.
1236
1237       <STRONG>mkhybrid</STRONG>           is            available            from
1238       <STRONG><A HREF="ftp://ftp.ge.ucl.ac.uk/pub/mkhfs">ftp://ftp.ge.ucl.ac.uk/pub/mkhfs</A></STRONG>    and    <STRONG>hfsutils</STRONG>   from
1239       <STRONG><A HREF="ftp://ftp.mars.org/pub/hfs">ftp://ftp.mars.org/pub/hfs</A></STRONG>
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288</PRE>
1289</BODY>
1290</HTML>
1291