Release 960331
[wine.git] / include / pe_image.h
blob799392a72129bca1aaab37100473ba0151c00c6c
1 #ifndef __WINE_PE_IMAGE_H
2 #define __WINE_PE_IMAGE_H
4 #include <sys/types.h>
5 #include "windows.h"
7 struct pe_data {
8 struct pe_header_s *pe_header;
9 struct pe_segment_table *pe_seg;
10 struct PE_Import_Directory *pe_import;
11 struct PE_Export_Directory *pe_export;
12 struct PE_Resource_Directory *pe_resource;
13 struct PE_Reloc_Block *pe_reloc;
14 int base_addr;
15 int load_addr;
16 int vma_size;
17 int resource_offset; /* offset to resource typedirectory in file */
20 typedef struct _WIN32_function{
21 char *name;
22 void *definition;
23 } WIN32_function;
25 typedef struct _WIN32_builtin{
26 char *name;
27 WIN32_function *functions;
28 WIN32_function *last_func;
29 const int *base;
30 struct _WIN32_builtin *next;
31 } WIN32_builtin;
33 struct w_files
35 struct w_files * next;
36 char * name; /* Name, as it appears in the windows binaries */
37 char * filename; /* Actual name of the unix file that satisfies this */
38 int type; /* DLL or EXE */
39 HINSTANCE hinstance;
40 HMODULE hModule;
41 int initialised;
42 struct mz_header_s *mz_header;
43 struct pe_data *pe;
44 OFSTRUCT ofs;
45 unsigned int load_addr;
46 WIN32_builtin* builtin;
50 extern int PE_unloadImage(struct w_files *wpnt);
51 extern int PE_StartProgram(struct w_files *wpnt);
52 extern void PE_InitDLL(HMODULE hModule);
53 extern void my_wcstombs(char * result, u_short * source, int len);
54 extern struct w_files *wine_files;
56 #endif /* __WINE_PE_IMAGE_H */