[Scummvm-cvs-logs] CVS: scummvm gameDetector.cpp,1.55,1.56 gui.cpp,1.39,1.40 insane.cpp,1.24,1.25 main.cpp,1.16,1.17 resource.cpp,1.76,1.77 saveload.cpp,1.43,1.44 script_v2.cpp,1.54,1.55 scumm.h,1.152,1.153 scummsys.h,1.34,1.35 scummvm.cpp,1.136,1.137 sound.cpp,1.78,1.79 stdafx.h,1.14,1.15

Drigo Zoxx drigo at users.sourceforge.net
Sun May 5 12:09:08 CEST 2002


Update of /cvsroot/scummvm/scummvm
In directory usw-pr-cvs1:/tmp/cvs-serv24417

Modified Files:
	gameDetector.cpp gui.cpp insane.cpp main.cpp resource.cpp 
	saveload.cpp script_v2.cpp scumm.h scummsys.h scummvm.cpp 
	sound.cpp stdafx.h 
Log Message:
Fixed some things for Macintosh ports

Index: gameDetector.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/gameDetector.cpp,v
retrieving revision 1.55
retrieving revision 1.56
diff -u -d -r1.55 -r1.56
--- gameDetector.cpp	4 May 2002 00:20:38 -0000	1.55
+++ gameDetector.cpp	5 May 2002 19:06:50 -0000	1.56
@@ -23,8 +23,13 @@
 
 #include "stdafx.h"
 #include "scumm.h"
+#ifndef macintosh
 #include "sound/mididrv.h"
 #include "sound/imuse.h"
+#else
+#include "mididrv.h"
+#include "imuse.h"
+#endif
 #include "gameDetector.h"
 
 
@@ -118,7 +123,7 @@
 
 void GameDetector::parseCommandLine(int argc, char **argv)
 {
-#if !defined(__APPLE__CW)
+#if !defined(MACOS_CARBON)
 	int i;
 	char *s;
 	char *current_option = NULL;
@@ -556,7 +561,7 @@
 #if defined (WIN32) && !defined(_WIN32_WCE)
 	/* MD_WINDOWS is default MidiDriver on windows targets */
 	if (drv == MD_AUTO) drv = MD_WINDOWS;
-#elif defined(__APPLE__)
+#elif defined(__APPLE__) || defined(macintosh)
 	/* MD_QTMUSIC is default MidiDriver on MacOS targets */
 	if (drv == MD_AUTO) drv = MD_QTMUSIC;
 #endif
@@ -573,8 +578,10 @@
 #if defined(UNIX) && !defined(__BEOS__)
     case MD_SEQ:        return MidiDriver_SEQ_create();
 #endif
-#if defined(__APPLE__)
+#if defined(__APPLE__) || defined(macintosh)
 	case MD_QTMUSIC:		return MidiDriver_QT_create();
+#endif
+#if defined(__APPLE__)
 	case MD_COREAUDIO:		return MidiDriver_CORE_create();
 #endif
 	}

Index: gui.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/gui.cpp,v
retrieving revision 1.39
retrieving revision 1.40
diff -u -d -r1.39 -r1.40
--- gui.cpp	1 May 2002 22:16:17 -0000	1.39
+++ gui.cpp	5 May 2002 19:06:50 -0000	1.40
@@ -21,8 +21,13 @@
 
 #include "stdafx.h"
 #include "scumm.h"
+#ifndef macintosh
 #include "sound/mididrv.h"
 #include "sound/imuse.h"
+#else
+#include "mididrv.h"
+#include "imuse.h"
+#endif
 #include "gui.h"
 #include "guimaps.h"
 

Index: insane.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/insane.cpp,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -d -r1.24 -r1.25
--- insane.cpp	4 May 2002 06:31:24 -0000	1.24
+++ insane.cpp	5 May 2002 19:06:50 -0000	1.25
@@ -19,7 +19,7 @@
  *
  */
 
-#if !defined(__APPLE__CW) && !defined(__MORPHOS__)
+#if !defined(macintosh) && !defined(__MORPHOS__)
 #define NEED_SDL_HEADERS
 #endif
 

Index: main.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/main.cpp,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -d -r1.16 -r1.17
--- main.cpp	5 May 2002 18:09:14 -0000	1.16
+++ main.cpp	5 May 2002 19:06:50 -0000	1.17
@@ -25,7 +25,11 @@
 #include "mididrv.h"
 #include "gameDetector.h"
 #include "gui.h"
+#ifndef macintosh
 #include "simon/simon.h"
+#else
+#include "simon.h"
+#endif
 #include "config-file.h"
 
 GameDetector detector;
@@ -94,8 +98,8 @@
 
 int main(int argc, char *argv[])
 {
-#if defined(MACOS)
-	// support for config file on macos
+#if defined(MACOS_SDL)
+	/* support for config file for macos SDL port */
 
 	char *argitem;
 	char *argstr;

Index: resource.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/resource.cpp,v
retrieving revision 1.76
retrieving revision 1.77
diff -u -d -r1.76 -r1.77
--- resource.cpp	1 May 2002 17:16:45 -0000	1.76
+++ resource.cpp	5 May 2002 19:06:50 -0000	1.77
@@ -178,7 +178,7 @@
 	debug(9, "openResourceFile(%s)", filename);
 
 	if (_resFilePath) {
-#if defined(__APPLE__CW)
+#if defined(macintosh)
 		sprintf(buf, ":%s.%d:%s", _resFilePath, _resFilePathId, filename);
 #else
 		sprintf(buf, "%s.%d\\%s", _resFilePath, _resFilePathId, filename);

Index: saveload.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saveload.cpp,v
retrieving revision 1.43
retrieving revision 1.44
diff -u -d -r1.43 -r1.44
--- saveload.cpp	5 May 2002 17:44:39 -0000	1.43
+++ saveload.cpp	5 May 2002 19:06:50 -0000	1.44
@@ -22,8 +22,13 @@
 
 #include "stdafx.h"
 #include "scumm.h"
+#ifndef macintosh
 #include "sound/mididrv.h"
 #include "sound/imuse.h"
+#else
+#include "mididrv.h"
+#include "imuse.h"
+#endif
 
 struct SaveGameHeader {
 	uint32 type;
@@ -158,7 +163,7 @@
 
 #ifndef _WIN32_WCE
 
-#if !defined(__APPLE__CW)
+#if !defined(macintosh)
 	const char *dir = getenv("SCUMMVM_SAVEPATH");
 	if (dir == NULL)
 		dir = "";

Index: script_v2.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/script_v2.cpp,v
retrieving revision 1.54
retrieving revision 1.55
diff -u -d -r1.54 -r1.55
--- script_v2.cpp	25 Apr 2002 08:53:10 -0000	1.54
+++ script_v2.cpp	5 May 2002 19:06:50 -0000	1.55
@@ -24,9 +24,13 @@
 #include "stdafx.h"
 #include "scumm.h"
 
+#ifndef macintosh
 #include "sound/mididrv.h"
-
 #include "sound/imuse.h"
+#else
+#include "mididrv.h"
+#include "imuse.h"
+#endif
 
 void Scumm::setupOpcodes2()
 {
@@ -2708,7 +2712,8 @@
 			setCursorImg(args[1], (uint) - 1, args[2]);
 			break;
 		case 13:
-			remapActor(derefActorSafe(args[1], "o6_miscOps:14"), args[2], args[3],
+			remapActor(derefActorSafe(args[1], "o6_miscOps:14"), args[2], args[3],
+
 								 args[4], -1);
 			break;
 		case 14:
@@ -2913,17 +2918,28 @@
 		push(_objs[i].height);
 		break;
 	case 211:
-		warning("o6_kernelFunction: getInput(%d)", args[1]);
-		/*
-		13 = thrust
-		336 = thrust
-		328 = thrust
-		27 = abord
-		97 = left
-		331 = left
-		115 = right
-		333 = tight
-		*/
+		warning("o6_kernelFunction: getInput(%d)", args[1]);
+
+		/*
+
+		13 = thrust
+
+		336 = thrust
+
+		328 = thrust
+
+		27 = abord
+
+		97 = left
+
+		331 = left
+
+		115 = right
+
+		333 = tight
+
+		*/
+
 		push(0);
 		break;
 	case 212:

Index: scumm.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm.h,v
retrieving revision 1.152
retrieving revision 1.153
diff -u -d -r1.152 -r1.153
--- scumm.h	5 May 2002 17:44:39 -0000	1.152
+++ scumm.h	5 May 2002 19:06:50 -0000	1.153
@@ -21,7 +21,11 @@
 
 #include "scummsys.h"
 #include "system.h"
+#ifndef macintosh
 #include "sound/mixer.h"
+#else
+#include "mixer.h"
+#endif
 #include "config-file.h"
 
 #define SCUMMVM_VERSION "0.2.0 devel"

Index: scummsys.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scummsys.h,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -d -r1.34 -r1.35
--- scummsys.h	5 May 2002 17:44:39 -0000	1.34
+++ scummsys.h	5 May 2002 19:06:50 -0000	1.35
@@ -131,10 +131,12 @@
 #define NORETURN
 #endif
 
-#elif defined(__APPLE__CW)
+#elif defined(macintosh)
 #include <stdlib.h>
 #include <stdio.h>
 
+#include "macos.h"
+
 #define scumm_stricmp strcmp
 inline char* strdup(char *buf) {return (char*)buf;};
 
@@ -214,37 +216,6 @@
 
 #define START_PACK_STRUCTS pack (push,1)
 #define END_PACK_STRUCTS   pack(pop)
-
-#elif (defined(__MWERKS__) && defined(macintosh) && !defined(__APPLE__CW))
-	
-	#define scumm_stricmp strcmp
-	
-	#define MACOS
-	#define NEED_STRDUP
-	
-	#define CHECK_HEAP
-
-	#define SCUMM_BIG_ENDIAN
-	#define SCUMM_NEED_ALIGNMENT
-	
-	#define FORCEINLINE inline
-	
-	#define NORETURN
-	
-	#define CDECL
-	
-	typedef unsigned char byte;
-	typedef unsigned char uint8;
-	typedef unsigned short uint16;
-	typedef unsigned long uint32;
-	typedef unsigned int uint;
-	typedef signed char int8;
-	typedef signed short int16;
-	typedef signed long int32;
-
-	#define START_PACK_STRUCTS options align=packed
-	#define END_PACK_STRUCTS options align=reset
-	#define GCC_PACK
 
 #else
 #error No system type defined

Index: scummvm.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scummvm.cpp,v
retrieving revision 1.136
retrieving revision 1.137
diff -u -d -r1.136 -r1.137
--- scummvm.cpp	4 May 2002 09:55:10 -0000	1.136
+++ scummvm.cpp	5 May 2002 19:06:50 -0000	1.137
@@ -22,8 +22,13 @@
 
 #include "stdafx.h"
 #include "scumm.h"
+#ifndef macintosh
 #include "sound/mididrv.h"
 #include "sound/imuse.h"
+#else
+#include "mididrv.h"
+#include "imuse.h"
+#endif
 #include "gui.h"
 #include "string.h"
 #include "gameDetector.h"
@@ -737,7 +742,7 @@
 	else
 		size = READ_BE_UINT32_UNALIGNED(ptr + 4);
 
-#if defined(__APPLE__CW)
+#if defined(macintosh)
 	sprintf(buf, ":dumps:%s%d.dmp", tag, idx);
 #else
 	sprintf(buf, "dumps/%s%d.dmp", tag, idx);

Index: sound.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/sound.cpp,v
retrieving revision 1.78
retrieving revision 1.79
diff -u -d -r1.78 -r1.79
--- sound.cpp	5 May 2002 17:44:39 -0000	1.78
+++ sound.cpp	5 May 2002 19:06:51 -0000	1.79
@@ -22,9 +22,15 @@
 
 #include "stdafx.h"
 #include "scumm.h"
+#ifndef macintosh
 #include "sound/mididrv.h"
 #include "sound/imuse.h"
 #include <sys/stat.h>
+#else
+#include "mididrv.h"
+#include "imuse.h"
+#include <stat.h>
+#endif
 
 #ifdef _WIN32_WCE
 extern void *bsearch(const void *, const void *, size_t,

Index: stdafx.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/stdafx.h,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -d -r1.14 -r1.15
--- stdafx.h	18 Apr 2002 21:40:23 -0000	1.14
+++ stdafx.h	5 May 2002 19:06:51 -0000	1.15
@@ -2,6 +2,9 @@
  * $Id$
  *
  * $Log$
+ * Revision 1.15  2002/05/05 19:06:51  drigo
+ * Fixed some things for Macintosh ports
+ *
  * Revision 1.14  2002/04/18 21:40:23  tomjoad
  * Reenable MorphOS Midi driver, small updates to CD open code (only when CD audio is requested) and start options
  *
@@ -99,7 +102,7 @@
 #include <devices/timer.h>
 #undef CMD_INVALID
 #endif
-#if !defined(__APPLE__CW) && !(defined(__MWERKS__) && defined(macintosh))
+#if !defined(macintosh)
 #include <sys/types.h>
 #include <sys/uio.h>
 #endif
@@ -129,8 +132,8 @@
 #define SCUMMVM_PLATFORM_VERSION  "X11 version"
 
 #else
-#ifdef __APPLE__CW
-#define SCUMMVM_PLATFORM_VERSION "Carbon Mac version"
+#ifdef macintosh
+#define SCUMMVM_PLATFORM_VERSION "Macintosh version"
 #else
 
 #ifdef SDL_COMPILEDVERSION





More information about the Scummvm-git-logs mailing list