X-Git-Url: http://shamusworld.gotdns.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fjaguar.h;h=ecd7197939b0abfd4e142d748a5cac312200aa53;hb=6d6e1b73eca47e97f2d092fda11ff85a10afb55b;hp=0855bee2e2faf5f13cb40b430554f4e77c99c1e8;hpb=2ae315f25e623cc8279d3c9012a3a166d86684c2;p=virtualjaguar diff --git a/src/jaguar.h b/src/jaguar.h index 0855bee..ecd7197 100644 --- a/src/jaguar.h +++ b/src/jaguar.h @@ -1,7 +1,11 @@ #ifndef __JAGUAR_H__ #define __JAGUAR_H__ +#include "types.h" + +#if 0 #include // Why??? (for memset, etc... Lazy!) Dunno why, but this just strikes me as wrong... +#include // For exit() #include "types.h" #include "log.h" #include "version.h" @@ -14,21 +18,19 @@ #include "objectp.h" #include "blitter.h" #include "clock.h" -//#include "anajoy.h" #include "joystick.h" #include "dac.h" #include "jagdasm.h" #include "cdrom.h" #include "eeprom.h" -//#include "cdi.h" -//#include "cdbios.h" +#endif // Exports from JAGUAR.CPP extern int32 jaguar_cpu_in_exec; extern uint32 jaguar_mainRom_crc32, jaguarRomSize, jaguarRunAddress; extern char * jaguar_eeproms_path; -extern char * whoName[9]; +extern const char * whoName[9]; void jaguar_init(void); void jaguar_reset(void); @@ -51,6 +53,14 @@ void JaguarExecuteNew(void); // Some handy macros to help converting native endian to big endian (jaguar native) // & vice versa +#define SET64(r, a, v) r[(a)] = ((v) & 0xFF00000000000000) >> 56, r[(a)+1] = ((v) & 0x00FF000000000000) >> 48, \ + r[(a)+2] = ((v) & 0x0000FF0000000000) >> 40, r[(a)+3] = ((v) & 0x000000FF00000000) >> 32, \ + r[(a)+4] = ((v) & 0xFF000000) >> 24, r[(a)+5] = ((v) & 0x00FF0000) >> 16, \ + r[(a)+6] = ((v) & 0x0000FF00) >> 8, r[(a)+7] = (v) & 0x000000FF +#define GET64(r, a) (((uint64)r[(a)] << 56) | ((uint64)r[(a)+1] << 48) | \ + ((uint64)r[(a)+2] << 40) | ((uint64)r[(a)+3] << 32) | \ + ((uint64)r[(a)+4] << 24) | ((uint64)r[(a)+5] << 16) | \ + ((uint64)r[(a)+6] << 8) | (uint64)r[(a)+7]) #define SET32(r, a, v) r[(a)] = ((v) & 0xFF000000) >> 24, r[(a)+1] = ((v) & 0x00FF0000) >> 16, \ r[(a)+2] = ((v) & 0x0000FF00) >> 8, r[(a)+3] = (v) & 0x000000FF #define GET32(r, a) ((r[(a)] << 24) | (r[(a)+1] << 16) | (r[(a)+2] << 8) | r[(a)+3])