forked from tecknicaltom/HT-Editor
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathilstruct.h
59 lines (52 loc) · 1.53 KB
/
ilstruct.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
/*
* HT Editor
* ilstruct.h
*
* Copyright (C) 1999-2002 Stefan Weyergraf
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
#ifndef __ILSTRUCT_H_
#define __ILSTRUCT_H_
#include "io/types.h"
#define IL_MAGIC0_0 'B'
#define IL_MAGIC0_1 'S'
#define IL_MAGIC0_2 'J'
#define IL_MAGIC0_3 'B'
#define IL_MAGIC1_0 'C'
#define IL_MAGIC1_1 'O'
#define IL_MAGIC1_2 'M'
#define IL_MAGIC1_3 '+'
struct IL_METADATA_SECTION {
uint32 magic PACKED;
uint16 major_version PACKED;
uint16 minor_version PACKED;
// if (minor_version==1) {
// uint32 unkown PACKED;
// uint32 version_string_length PACKED;
// char version_string[align(version_string_length, 4)];
// }
// byte zero1, zero2;
// uint16 number_of_entries;
};
struct IL_METADATA_SECTION_ENTRY {
uint32 offset PACKED;
uint32 size PACKED;
//char name[]; // zero_terminated
// align(4)
// uint32 ref ?;
};
extern byte IL_METADATA_SECTION_struct[];
extern byte IL_METADATA_SECTION_ENTRY_struct[];
#endif