]> Shamusworld >> Repos - virtualjaguar/commitdiff
Small fix to allow app.cpp to compile on win32.
authorShamus Hammons <jlhamm@acm.org>
Sun, 26 Jun 2011 21:29:02 +0000 (21:29 +0000)
committerShamus Hammons <jlhamm@acm.org>
Sun, 26 Jun 2011 21:29:02 +0000 (21:29 +0000)
src/gui/app.cpp
src/memory.cpp
src/memory.h

index 1e36fe4c6450b2d515276aa2d039a0e19fe09aa9..bb0f9243bf7e7f5471d2d446e26d4a69cf4913a4 100644 (file)
@@ -20,6 +20,9 @@
 #include "mainwin.h"
 #include "types.h"
 
+// Apparently on other archs, SDL is hijacking main, so let's do this:
+#undef main
+
 // Here's the main application loop--short and simple...
 int main(int argc, char * argv[])
 {
index c1b299a5e2b38b4f18d1ae6cac3e10e2f64cdb2e..0343f612755aa5c5bc262a6a6aebf7923ea1b51c 100644 (file)
@@ -148,6 +148,8 @@ uint32 butch, dscntrl, ds_data, i2cntrl, sbcntrl, subdata, subdatb, sb_time, fif
 //this isn't endian safe...
 #define BSWAP64(x) ((htonl(x & 0xFFFFFFFF) << 32) | htonl(x >> 32))
 // Actually, we use ESAFExx() macros instead of this, and we use GCC to check the endianness...
+// Acutally, considering that "byteswap.h" doesn't exist elsewhere, the above
+// is probably our best bet here. Just need to rename them to ESAFExx().
 
 uint16 & memcon1   = *((uint16 *)&jagMemSpace[0xF00000]);
 uint16 & memcon2   = *((uint16 *)&jagMemSpace[0xF00002]);
index 78fb3b8c49f903c71a5e46e0b90cb923b0524b7b..900325e82a6259540bbaf020626bba611c9af828 100644 (file)
@@ -88,6 +88,7 @@ extern const char * whoName[9];
 #define GET16(r, a)            ((r[(a)] << 8) | r[(a)+1])
 
 //This doesn't seem to work on OSX. So have to figure something else out. :-(
+//byteswap.h doesn't exist on OSX.
 #if 0
 // This is GCC specific, but we can fix that if we need to...
 // Big plus of this approach is that these compile down to single instructions on little