Commit | Line | Data |
---|---|---|
cf76e892 JPM |
1 | // |
2 | // FILE.H | |
3 | // | |
4 | // File support | |
5 | // | |
6 | // JPM = Jean-Paul Mari <djipi.mari@gmail.com> | |
7 | // | |
8 | // Who When What | |
9 | // --- ---------- ----------------------------------------------------------- | |
10 | // JPM 06/15/2016 ELF format support | |
11 | // JPM 06/19/2016 Soft debugger support | |
12 | // | |
13 | ||
14 | #ifndef __FILE_H__ | |
15 | #define __FILE_H__ | |
16 | ||
17 | #include <stdint.h> | |
18 | ||
be44e757 | 19 | #if 0 |
cf76e892 JPM |
20 | #ifdef __cplusplus |
21 | extern "C" { | |
22 | #endif | |
be44e757 | 23 | #endif |
cf76e892 JPM |
24 | |
25 | enum FileType { FT_SOFTWARE=0, FT_EEPROM, FT_LABEL, FT_BOXART, FT_OVERLAY }; | |
26 | // JST = Jaguar Software Type | |
27 | enum { JST_NONE = 0, JST_ROM, JST_ALPINE, JST_ABS_TYPE1, JST_ABS_TYPE2, JST_JAGSERVER, JST_WTFOMGBBQ, JST_ELF32 }; | |
28 | ||
be44e757 JPM |
29 | extern uint32_t JaguarLoadROM(uint8_t * &rom, char * path); |
30 | extern bool JaguarLoadFile(char * path); | |
31 | extern bool AlpineLoadFile(char * path); | |
32 | extern bool DebuggerLoadFile(char * path); | |
33 | extern uint32_t GetFileFromZIP(const char * zipFile, FileType type, uint8_t * &buffer); | |
34 | extern uint32_t GetFileDBIdentityFromZIP(const char * zipFile); | |
35 | extern bool FindFileInZIPWithCRC32(const char * zipFile, uint32_t crc); | |
36 | extern uint32_t ParseFileType(uint8_t * buffer, uint32_t size); | |
37 | extern bool HasUniversalHeader(uint8_t * rom, uint32_t romSize); | |
cf76e892 | 38 | |
be44e757 | 39 | #if 0 |
cf76e892 JPM |
40 | #ifdef __cplusplus |
41 | } | |
42 | #endif | |
be44e757 | 43 | #endif |
cf76e892 JPM |
44 | |
45 | #endif // __FILE_H__ |