Imported Upstream version 1.1.11
[platform/upstream/cdrkit.git] / 3rd-party / zisofs_tools / iso9660.h
1 /*
2  * This file has been modified for the cdrkit suite.
3  *
4  * The behaviour and appearence of the program code below can differ to a major
5  * extent from the version distributed by the original author(s).
6  *
7  * For details, see Changelog file distributed with the cdrkit package. If you
8  * received this file from another source then ask the distributing person for
9  * a log of modifications.
10  *
11  */
12
13 #ident "$Id: iso9660.h,v 1.4 2006/07/04 04:57:42 hpa Exp $"
14 /* ----------------------------------------------------------------------- *
15  *   
16  *   Copyright 2001 H. Peter Anvin - All Rights Reserved
17  *
18  *   This program is free software; you can redistribute it and/or modify
19  *   it under the terms of the GNU General Public License as published by
20  *   the Free Software Foundation, Inc., 675 Mass Ave, Cambridge MA 02139,
21  *   USA; either version 2 of the License, or (at your option) any later
22  *   version; incorporated herein by reference.
23  *
24  * ----------------------------------------------------------------------- */
25
26 /* zisofs definitions */
27
28 #ifndef ISO9660_H
29 #define ISO9660_H
30
31 #ifndef CBLOCK_SIZE_LG2
32 #define CBLOCK_SIZE_LG2 15      /* Compressed block size */
33 #endif
34 #define CBLOCK_SIZE     (1 << CBLOCK_SIZE_LG2)
35
36 /* Compressed file magic */
37 extern const unsigned char zisofs_magic[8];
38
39 /* VERY VERY VERY IMPORTANT: Must be a multiple of 4 bytes */
40 struct compressed_file_header {
41   char magic[8];
42   char uncompressed_len[4];
43   unsigned char header_size;
44   unsigned char block_size;
45   char reserved[2];             /* Reserved for future use, MBZ */
46 };
47
48 /* iso9660 integer formats */
49 void set_721(void *, unsigned int);
50 unsigned int get_721(void *);
51 void set_722(void *, unsigned int);
52 unsigned int get_722(void *);
53 void set_723(void *, unsigned int);
54 void set_731(void *, unsigned int);
55 unsigned int get_731(void *);
56 void set_732(void *, unsigned int);
57 unsigned int get_732(void *);
58 void set_733(void *, unsigned int);
59 #define get_723(x) get_721(x)
60 #define get_733(x) get_731(x)
61
62 #endif /* ISO9660_H */