[Scummvm-cvs-logs] SF.net SVN: scummvm: [31888] scummvm/trunk

jvprat at users.sourceforge.net jvprat at users.sourceforge.net
Tue May 6 05:00:26 CEST 2008


Revision: 31888
          http://scummvm.svn.sourceforge.net/scummvm/?rev=31888&view=rev
Author:   jvprat
Date:     2008-05-05 20:00:26 -0700 (Mon, 05 May 2008)

Log Message:
-----------
Allow static and dynamic plugins to be used at the same time

Modified Paths:
--------------
    scummvm/trunk/Makefile.common
    scummvm/trunk/backends/platform/PalmOS/Src/modules.cpp
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/compile.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_agi.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_agos.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_cine.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_cruise.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_drascula.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_gob.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_igor.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_kyra.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_lure.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_parallaction.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_queen.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_saga.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_scumm.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_sky.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_sword1.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_sword2.h
    scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_touche.h
    scummvm/trunk/backends/platform/ds/arm9/makefile
    scummvm/trunk/backends/platform/ds/arm9/source/dsmain.cpp
    scummvm/trunk/backends/platform/ds/arm9/source/wordcompletion.cpp
    scummvm/trunk/backends/platform/gp32/Makefile
    scummvm/trunk/backends/platform/wince/Makefile
    scummvm/trunk/base/commandLine.cpp
    scummvm/trunk/base/plugins.cpp
    scummvm/trunk/base/plugins.h
    scummvm/trunk/configure
    scummvm/trunk/engines/agi/detection.cpp
    scummvm/trunk/engines/agi/module.mk
    scummvm/trunk/engines/agos/detection.cpp
    scummvm/trunk/engines/agos/module.mk
    scummvm/trunk/engines/cine/detection.cpp
    scummvm/trunk/engines/cine/module.mk
    scummvm/trunk/engines/cruise/detection.cpp
    scummvm/trunk/engines/cruise/module.mk
    scummvm/trunk/engines/drascula/detection.cpp
    scummvm/trunk/engines/drascula/module.mk
    scummvm/trunk/engines/engines.mk
    scummvm/trunk/engines/gob/detection.cpp
    scummvm/trunk/engines/gob/module.mk
    scummvm/trunk/engines/igor/detection.cpp
    scummvm/trunk/engines/igor/module.mk
    scummvm/trunk/engines/kyra/detection.cpp
    scummvm/trunk/engines/kyra/module.mk
    scummvm/trunk/engines/lure/detection.cpp
    scummvm/trunk/engines/lure/module.mk
    scummvm/trunk/engines/m4/detection.cpp
    scummvm/trunk/engines/m4/module.mk
    scummvm/trunk/engines/made/detection.cpp
    scummvm/trunk/engines/made/module.mk
    scummvm/trunk/engines/parallaction/detection.cpp
    scummvm/trunk/engines/parallaction/module.mk
    scummvm/trunk/engines/queen/module.mk
    scummvm/trunk/engines/queen/queen.cpp
    scummvm/trunk/engines/saga/detection.cpp
    scummvm/trunk/engines/saga/module.mk
    scummvm/trunk/engines/scumm/actor.cpp
    scummvm/trunk/engines/scumm/akos.cpp
    scummvm/trunk/engines/scumm/camera.cpp
    scummvm/trunk/engines/scumm/charset.cpp
    scummvm/trunk/engines/scumm/charset.h
    scummvm/trunk/engines/scumm/detection.cpp
    scummvm/trunk/engines/scumm/detection_tables.h
    scummvm/trunk/engines/scumm/gfx.cpp
    scummvm/trunk/engines/scumm/gfx.h
    scummvm/trunk/engines/scumm/he/cup_player_he.h
    scummvm/trunk/engines/scumm/he/floodfill_he.h
    scummvm/trunk/engines/scumm/he/intern_he.h
    scummvm/trunk/engines/scumm/he/logic_he.h
    scummvm/trunk/engines/scumm/he/resource_he.cpp
    scummvm/trunk/engines/scumm/he/sprite_he.h
    scummvm/trunk/engines/scumm/he/wiz_he.h
    scummvm/trunk/engines/scumm/imuse_digi/dimuse.h
    scummvm/trunk/engines/scumm/imuse_digi/dimuse_tables.h
    scummvm/trunk/engines/scumm/imuse_digi/dimuse_track.h
    scummvm/trunk/engines/scumm/input.cpp
    scummvm/trunk/engines/scumm/insane/insane.h
    scummvm/trunk/engines/scumm/intern.h
    scummvm/trunk/engines/scumm/module.mk
    scummvm/trunk/engines/scumm/nut_renderer.h
    scummvm/trunk/engines/scumm/object.cpp
    scummvm/trunk/engines/scumm/palette.cpp
    scummvm/trunk/engines/scumm/resource.cpp
    scummvm/trunk/engines/scumm/room.cpp
    scummvm/trunk/engines/scumm/saveload.cpp
    scummvm/trunk/engines/scumm/script_v6.cpp
    scummvm/trunk/engines/scumm/scumm.cpp
    scummvm/trunk/engines/scumm/smush/smush_player.h
    scummvm/trunk/engines/scumm/sound.cpp
    scummvm/trunk/engines/scumm/string.cpp
    scummvm/trunk/engines/scumm/vars.cpp
    scummvm/trunk/engines/scumm/verbs.cpp
    scummvm/trunk/engines/sky/module.mk
    scummvm/trunk/engines/sky/sky.cpp
    scummvm/trunk/engines/sword1/module.mk
    scummvm/trunk/engines/sword1/sword1.cpp
    scummvm/trunk/engines/sword2/module.mk
    scummvm/trunk/engines/sword2/sword2.cpp
    scummvm/trunk/engines/touche/detection.cpp
    scummvm/trunk/engines/touche/module.mk
    scummvm/trunk/sound/mididrv.cpp

Modified: scummvm/trunk/Makefile.common
===================================================================
--- scummvm/trunk/Makefile.common	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/Makefile.common	2008-05-06 03:00:26 UTC (rev 31888)
@@ -22,11 +22,11 @@
 
 # After the game specific modules follow the shared modules
 MODULES += \
-	engines \
 	gui \
 	graphics \
 	sound \
 	common \
+	engines \
 	backends
 
 ifdef USE_MT32EMU
@@ -182,22 +182,22 @@
 
 # Engine data files
 DIST_FILES_ENGINEDATA=
-ifndef DISABLE_IGOR
+ifdef ENABLE_IGOR
 DIST_FILES_ENGINEDATA+=igor.tbl
 endif
-ifndef DISABLE_KYRA
+ifdef ENABLE_KYRA
 DIST_FILES_ENGINEDATA+=kyra.dat
 endif
-ifndef DISABLE_LURE
+ifdef ENABLE_LURE
 DIST_FILES_ENGINEDATA+=lure.dat
 endif
-ifndef DISABLE_M4
+ifdef ENABLE_M4
 DIST_FILES_ENGINEDATA+=m4.dat
 endif
-ifndef DISABLE_QUEEN
+ifdef ENABLE_QUEEN
 DIST_FILES_ENGINEDATA+=queen.tbl
 endif
-ifndef DISABLE_SKY
+ifdef ENABLE_SKY
 DIST_FILES_ENGINEDATA+=sky.cpt
 endif
 DIST_FILES_ENGINEDATA:=$(addprefix $(srcdir)/dists/engine-data/,$(DIST_FILES_ENGINEDATA))

Modified: scummvm/trunk/backends/platform/PalmOS/Src/modules.cpp
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/modules.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/modules.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -87,9 +87,9 @@
 #ifdef PALMOS_NATIVE
 			result = GET_MODEARM;
 #else
-#	if	!defined(DISABLE_SCUMM) || \
-		!defined(DISABLE_AGOS) || \
-		!defined(DISABLE_SWORD1)
+#	if	defined(ENABLE_SCUMM) || \
+		defined(ENABLE_AGOS) || \
+		defined(ENABLE_SWORD1)
 			result = GET_DATACOMMON|GET_DATAENGINE|GET_MODE68K;
 #	else
 			result = GET_DATACOMMON|GET_MODE68K;

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/compile.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/compile.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/compile.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -26,27 +26,27 @@
 #ifndef __COMPILE_H__
 #define __COMPILE_H__
 
-#define DISABLE_SCUMM
-#define DISABLE_SCUMM_7_8
-#define DISABLE_HE
+#undef ENABLE_SCUMM
+#undef ENABLE_SCUMM_7_8
+#undef ENABLE_HE
 
-#define DISABLE_AGOS
-#define DISABLE_SKY
-#define DISABLE_SWORD1
-#define DISABLE_SWORD2
-#define DISABLE_QUEEN
-#define DISABLE_SAGA
-#define DISABLE_KYRA
-#define DISABLE_AWE
-#define DISABLE_GOB
-#define DISABLE_LURE
-#define DISABLE_CINE
-#define DISABLE_AGI
-#define DISABLE_TOUCHE
-#define DISABLE_PARALLACTION
-#define DISABLE_CRUISE
-#define DISABLE_DRASCULA
-#define DISABLE_IGOR
+#undef ENABLE_AGOS
+#undef ENABLE_SKY
+#undef ENABLE_SWORD1
+#undef ENABLE_SWORD2
+#undef ENABLE_QUEEN
+#undef ENABLE_SAGA
+#undef ENABLE_KYRA
+#undef ENABLE_AWE
+#undef ENABLE_GOB
+#undef ENABLE_LURE
+#undef ENABLE_CINE
+#undef ENABLE_AGI
+#undef ENABLE_TOUCHE
+#undef ENABLE_PARALLACTION
+#undef ENABLE_CRUISE
+#undef ENABLE_DRASCULA
+#undef ENABLE_IGOR
 
 // ScummVM
 #define DISABLE_HQ_SCALERS

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_agi.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_agi.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_agi.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,7 +2,7 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_AGI
+#define ENABLE_AGI STATIC_PLUGIN
 
 #undef USE_MAD
 #undef USE_VORBIS

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_agos.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_agos.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_agos.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,6 +2,6 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_AGOS
+#define ENABLE_AGOS STATIC_PLUGIN
 
 #endif

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_cine.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_cine.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_cine.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,7 +2,7 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_CINE
+#define ENABLE_CINE STATIC_PLUGIN
 #define _DEBUG
 
 #undef USE_MAD

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_cruise.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_cruise.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_cruise.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,7 +2,7 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_CRUISE
+#define ENABLE_CRUISE STATIC_PLUGIN
 
 #undef USE_MAD
 #undef USE_VORBIS

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_drascula.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_drascula.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_drascula.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,6 +2,6 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_DRASCULA
+#define ENABLE_DRASCULA STATIC_PLUGIN
 
 #endif

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_gob.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_gob.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_gob.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,6 +2,6 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_GOB
+#define ENABLE_GOB STATIC_PLUGIN
 
 #endif

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_igor.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_igor.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_igor.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,6 +2,6 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_IGOR
+#define ENABLE_IGOR STATIC_PLUGIN
 
 #endif

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_kyra.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_kyra.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_kyra.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,6 +2,6 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_KYRA
+#define ENABLE_KYRA
 
 #endif

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_lure.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_lure.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_lure.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,7 +2,7 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_LURE
+#define ENABLE_LURE STATIC_PLUGIN
 
 #undef USE_MAD
 #undef USE_VORBIS

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_parallaction.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_parallaction.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_parallaction.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,7 +2,7 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_PARALLACTION
+#define ENABLE_PARALLACTION STATIC_PLUGIN
 
 #undef USE_MAD
 #undef USE_VORBIS

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_queen.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_queen.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_queen.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,6 +2,6 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_QUEEN
+#define ENABLE_QUEEN STATIC_PLUGIN
 
 #endif

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_saga.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_saga.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_saga.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,6 +2,6 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_SAGA
+#define ENABLE_SAGA STATIC_PLUGIN
 
 #endif

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_scumm.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_scumm.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_scumm.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,9 +2,9 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_SCUMM
-#undef DISABLE_SCUMM_7_8
-#undef DISABLE_HE
+#define ENABLE_SCUMM STATIC_PLUGIN
+#define ENABLE_SCUMM_7_8
+#define ENABLE_HE
 
 #define USE_ARM_GFX_ASM
 #define USE_ARM_SMUSH_ASM

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_sky.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_sky.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_sky.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,6 +2,6 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_SKY
+#define ENABLE_SKY STATIC_PLUGIN
 
 #endif

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_sword1.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_sword1.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_sword1.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,7 +2,7 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_SWORD1
+#define ENABLE_SWORD1
 #define USE_MPEG2
 #define USE_VORBIS
 

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_sword2.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_sword2.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_sword2.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,7 +2,7 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_SWORD2
+#define ENABLE_SWORD2 STATIC_PLUGIN
 #undef _DEBUG
 #define USE_MPEG2
 #define USE_VORBIS

Modified: scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_touche.h
===================================================================
--- scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_touche.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/PalmOS/Src/prefixes/native_touche.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,6 +2,6 @@
 #define PREFIX_H
 
 #include "native_common.h"
-#undef DISABLE_TOUCHE
+#define ENABLE_TOUCHE STATIC_PLUGIN
 
 #endif

Modified: scummvm/trunk/backends/platform/ds/arm9/makefile
===================================================================
--- scummvm/trunk/backends/platform/ds/arm9/makefile	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/ds/arm9/makefile	2008-05-06 03:00:26 UTC (rev 31888)
@@ -86,184 +86,54 @@
 ifdef DS_BUILD_A
 	DEFINES = -DDS_SCUMM_BUILD -DDS_BUILD_A -DUSE_ARM_GFX_ASM
 	LOGO = logoa.bmp
-	DISABLE_HE = 1
-	#DISABLE_SCUMM = 1
-	DISABLE_SCUMM_7_8 = 1
-	DISABLE_AGOS = 1
-	DISABLE_SKY = 1
-	DISABLE_SWORD1 = 1
-	DISABLE_SWORD2 = 1
-	DISABLE_QUEEN = 1
-	DISABLE_SAGA = 1
-	DISABLE_KYRA = 1
-	DISABLE_GOB = 1
-	DISABLE_LURE = 1
-	DISABLE_CINE = 1
-	DISABLE_AGI = 1
-	DISABLE_TOUCHE = 1
-	DISABLE_PARALLACTION = 1
-	DISABLE_CRUISE = 1
+	ENABLE_SCUMM = STATIC_PLUGIN
 	USE_ARM_GFX_ASM = 1
-	DISABLE_CRUISE = 1
-	DISABLE_DRASCULA = 1
-	DISABLE_IGOR = 1
 	BUILD=scummvm-A
 endif
 
 ifdef DS_BUILD_B
 	DEFINES = -DDS_NON_SCUMM_BUILD -DDS_BUILD_B
 	LOGO = logob.bmp
-	DISABLE_HE = 1
-	DISABLE_SCUMM = 1
-	DISABLE_SCUMM_7_8 = 1
-	DISABLE_AGOS = 1
-	#DISABLE_SKY = 1#
-	DISABLE_SWORD1 = 1
-	DISABLE_SWORD2 = 1
-	#DISABLE_QUEEN = 1#
-	DISABLE_SAGA = 1
-	DISABLE_KYRA = 1
-	DISABLE_GOB = 1
-	DISABLE_LURE = 1
-	DISABLE_CINE = 1
-	DISABLE_AGI = 1
-	DISABLE_TOUCHE = 1
-	DISABLE_PARALLACTION = 1
-	DISABLE_CRUISE = 1
-	DISABLE_DRASCULA = 1
-	DISABLE_IGOR = 1
+	ENABLE_SKY = STATIC_PLUGIN
+	ENABLE_QUEEN = STATIC_PLUGIN
 	BUILD=scummvm-B
 endif
 
 ifdef DS_BUILD_C
 	DEFINES = -DDS_NON_SCUMM_BUILD -DDS_BUILD_C
 	LOGO = logoc.bmp
-	DISABLE_HE = 1
-	DISABLE_SCUMM = 1
-	DISABLE_SCUMM_7_8 = 1
-	#DISABLE_AGOS = 1
-	DISABLE_SKY = 1
-	DISABLE_SWORD1 = 1
-	DISABLE_SWORD2 = 1
-	DISABLE_QUEEN = 1
-	DISABLE_SAGA = 1
-	DISABLE_KYRA = 1
-	DISABLE_GOB = 1
-	DISABLE_LURE = 1
-	DISABLE_CINE = 1
-	DISABLE_AGI = 1
-	DISABLE_TOUCHE = 1
-	DISABLE_PARALLACTION = 1
-	DISABLE_CRUISE = 1
-	DISABLE_DRASCULA = 1
-	DISABLE_IGOR = 1
+	ENABLE_AGOS = STATIC_PLUGIN
 	BUILD=scummvm-C
 endif
 
 ifdef DS_BUILD_D
 	DEFINES = -DDS_NON_SCUMM_BUILD -DDS_BUILD_D
 	LOGO = logod.bmp
-	DISABLE_HE = 1
-	DISABLE_SCUMM = 1
-	DISABLE_SCUMM_7_8 = 1
-	DISABLE_AGOS = 1
-	DISABLE_SKY = 1
-	DISABLE_SWORD1 = 1
-	DISABLE_SWORD2 = 1
-	DISABLE_QUEEN = 1
-	DISABLE_SAGA = 1
-	DISABLE_KYRA = 1
-	#DISABLE_GOB = 1
-	DISABLE_LURE = 1
-	#DISABLE_CINE = 1
-	#DISABLE_AGI = 1
-	DISABLE_TOUCHE = 1
-	DISABLE_PARALLACTION = 1
-	DISABLE_CRUISE = 1
-	DISABLE_DRASCULA = 1
-	DISABLE_IGOR = 1
+	ENABLE_GOB = STATIC_PLUGIN
+	ENABLE_CINE = STATIC_PLUGIN
+	ENABLE_AGI = STATIC_PLUGIN
 	BUILD=scummvm-D
 endif
 
-
 ifdef DS_BUILD_E
 	DEFINES = -DDS_NON_SCUMM_BUILD -DDS_BUILD_E
 	LOGO = logoe.bmp
-	DISABLE_HE = 1
-	DISABLE_SCUMM = 1
-	DISABLE_SCUMM_7_8 = 1
-	DISABLE_AGOS = 1
-	DISABLE_SKY = 1
-	DISABLE_SWORD1 = 1
-	DISABLE_SWORD2 = 1
-	DISABLE_QUEEN = 1
-	#DISABLE_SAGA = 1
-	DISABLE_KYRA = 1
-	DISABLE_GOB = 1
-	DISABLE_LURE = 1
-	DISABLE_CINE = 1
-	DISABLE_AGI = 1
-	DISABLE_TOUCHE = 1
-	DISABLE_PARALLACTION = 1
-	DISABLE_CRUISE = 1
-	DISABLE_DRASCULA = 1
-	DISABLE_IGOR = 1
+	ENABLE_SAGA = STATIC_PLUGIN
 	BUILD=scummvm-E
 endif
 
-
 ifdef DS_BUILD_F
 	DEFINES = -DDS_NON_SCUMM_BUILD -DDS_BUILD_F
 	LOGO = logof.bmp
-	DISABLE_HE = 1
-	DISABLE_SCUMM = 1
-	DISABLE_SCUMM_7_8 = 1
-	DISABLE_AGOS = 1
-	DISABLE_SKY = 1
-	DISABLE_SWORD1 = 1
-	DISABLE_SWORD2 = 1
-	DISABLE_QUEEN = 1
-	DISABLE_SAGA = 1
-	#DISABLE_KYRA = 1
-	DISABLE_GOB = 1
-	DISABLE_LURE = 1
-	DISABLE_CINE = 1
-	DISABLE_AGI = 1
-	DISABLE_TOUCHE = 1
-	DISABLE_PARALLACTION = 1
-	DISABLE_CRUISE = 1
-	DISABLE_DRASCULA = 1
-	DISABLE_IGOR = 1
+	ENABLE_KYRA = STATIC_PLUGIN
 	BUILD=scummvm-F
-
 endif
 
-
-
 ifdef DS_BUILD_G
 	DEFINES = -DDS_NON_SCUMM_BUILD -DDS_BUILD_G
 	LOGO = logog.bmp
-	DISABLE_HE = 1
-	DISABLE_SCUMM = 1
-	DISABLE_SCUMM_7_8 = 1
-	DISABLE_AGOS = 1
-	DISABLE_SKY = 1
-	DISABLE_SWORD1 = 1
-	DISABLE_SWORD2 = 1
-	DISABLE_QUEEN = 1
-	DISABLE_SAGA = 1
-	DISABLE_KYRA = 1
-	DISABLE_GOB = 1
-	#DISABLE_LURE = 1
-	DISABLE_CINE = 1
-	DISABLE_AGI = 1
-	DISABLE_TOUCHE = 1
-	DISABLE_PARALLACTION = 1
-	DISABLE_CRUISE = 1
-	DISABLE_DRASCULA = 1
-	DISABLE_IGOR = 1
+	ENABLE_LURE = STATIC_PLUGIN
 	BUILD=scummvm-G
-
 endif
 
 

Modified: scummvm/trunk/backends/platform/ds/arm9/source/dsmain.cpp
===================================================================
--- scummvm/trunk/backends/platform/ds/arm9/source/dsmain.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/ds/arm9/source/dsmain.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -359,7 +359,7 @@
 
 
 void saveGameBackBuffer() {
-#ifdef DISABLE_SCUMM
+#ifndef ENABLE_SCUMM
     if (savedBuffer == NULL) savedBuffer = new u8[gameWidth * gameHeight];
     for (int r = 0; r < gameHeight; r++) {
 
@@ -375,7 +375,7 @@
 }
 
 void restoreGameBackBuffer() {
-#ifdef DISABLE_SCUMM
+#ifndef ENABLE_SCUMM
 	if (savedBuffer) {
 		for (int r = 0; r < gameHeight; r++) {
 

Modified: scummvm/trunk/backends/platform/ds/arm9/source/wordcompletion.cpp
===================================================================
--- scummvm/trunk/backends/platform/ds/arm9/source/wordcompletion.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/ds/arm9/source/wordcompletion.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2,7 +2,7 @@
 #include "engines/agi/agi.h"
 #include "osystem_ds.h"
 
-#ifndef DISABLE_AGI
+#ifdef ENABLE_AGI
 
 namespace DS {
 // Default dictionary is about 64Kb, so 128Kb should be enough for future expansion

Modified: scummvm/trunk/backends/platform/gp32/Makefile
===================================================================
--- scummvm/trunk/backends/platform/gp32/Makefile	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/gp32/Makefile	2008-05-06 03:00:26 UTC (rev 31888)
@@ -153,26 +153,26 @@
 DISABLE_SCALERS = 1
 DISABLE_HQ_SCALERS = 1
 
-#DISABLE_SCUMM = 1
+ENABLE_SCUMM = STATIC_PLUGIN
 
 # We can play The Dig with GP32 -- without any movies/musics/voices. But who would do that?
-DISABLE_SCUMM_7_8 = 1
-DISABLE_HE = 1
+#ENABLE_SCUMM_7_8 = 1
+#ENABLE_HE = 1
 
-#DISABLE_AGOS = 1
-#DISABLE_SKY = 1
-#DISABLE_QUEEN = 1
-#DISABLE_GOB = 1
-#DISABLE_LURE = 1
-#DISABLE_CINE = 1
-#DISABLE_SAGA = 1
-#DISABLE_KYRA = 1
-#DISABLE_AGI = 1
+ENABLE_AGOS = STATIC_PLUGIN
+ENABLE_SKY = STATIC_PLUGIN
+ENABLE_QUEEN = STATIC_PLUGIN
+ENABLE_GOB = STATIC_PLUGIN
+ENABLE_LURE = STATIC_PLUGIN
+ENABLE_CINE = STATIC_PLUGIN
+ENABLE_SAGA = STATIC_PLUGIN
+ENABLE_KYRA = STATIC_PLUGIN
+ENABLE_AGI = STATIC_PLUGIN
 
 # The engines below are not supported on the GP32 port so there is
 # no point compiling support into the binary.
-DISABLE_SWORD1 = 1
-DISABLE_SWORD2 = 1
+#ENABLE_SWORD1 = STATIC_PLUGIN
+#ENABLE_SWORD2 = STATIC_PLUGIN
 
 #######################################################################
 # Misc stuff - you should normally never have to edit this            #

Modified: scummvm/trunk/backends/platform/wince/Makefile
===================================================================
--- scummvm/trunk/backends/platform/wince/Makefile	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/backends/platform/wince/Makefile	2008-05-06 03:00:26 UTC (rev 31888)
@@ -13,27 +13,28 @@
 ## Do you want a build using plugins?
 
 #BUILD_PLUGINS = 1
+# TODO: You'll need to change STATIC_PLUGIN to DYNAMIC_PLUGIN below
 
 ########################################################################
-## Disable whichever engines you want here
+## Enable whichever engines you want here
 
-#DISABLE_SCUMM = 1
-#DISABLE_SKY = 1
-#DISABLE_QUEEN = 1
-#DISABLE_GOB = 1
-#DISABLE_LURE = 1
-#DISABLE_CINE = 1
-#DISABLE_SAGA = 1
-#DISABLE_KYRA = 1
-#DISABLE_AGI = 1
-#DISABLE_AGOS = 1
-#DISABLE_SWORD1 = 1
-#DISABLE_SWORD2 = 1
-#DISABLE_TOUCHE = 1
-#DISABLE_PARALLACTION = 1
-DISABLE_CRUISE = 1
-DISABLE_DRASCULA = 1
-DISABLE_IGOR = 1
+ENABLE_SCUMM = STATIC_PLUGIN
+ENABLE_SKY = STATIC_PLUGIN
+ENABLE_QUEEN = STATIC_PLUGIN
+ENABLE_GOB = STATIC_PLUGIN
+ENABLE_LURE = STATIC_PLUGIN
+ENABLE_CINE = STATIC_PLUGIN
+ENABLE_SAGA = STATIC_PLUGIN
+ENABLE_KYRA = STATIC_PLUGIN
+ENABLE_AGI = STATIC_PLUGIN
+ENABLE_AGOS = STATIC_PLUGIN
+ENABLE_SWORD1 = STATIC_PLUGIN
+ENABLE_SWORD2 = STATIC_PLUGIN
+ENABLE_TOUCHE = STATIC_PLUGIN
+ENABLE_PARALLACTION = STATIC_PLUGIN
+#ENABLE_CRUISE = STATIC_PLUGIN
+#ENABLE_DRASCULA = STATIC_PLUGIN
+#ENABLE_IGOR = STATIC_PLUGIN
 
 ########################################################################
 ## Pick which libraries you want to use here

Modified: scummvm/trunk/base/commandLine.cpp
===================================================================
--- scummvm/trunk/base/commandLine.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/base/commandLine.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -116,14 +116,14 @@
 	"  --render-mode=MODE       Enable additional render modes (cga, ega, hercGreen,\n"
 	"                           hercAmber, amiga)\n"
 	"\n"
-#if !defined(DISABLE_SKY) || !defined(DISABLE_QUEEN)
+#if defined(ENABLE_SKY) || defined(ENABLE_QUEEN)
 	"  --alt-intro              Use alternative intro for CD versions of Beneath a\n"
 	"                           Steel Sky and Flight of the Amazon Queen\n"
 #endif
 	"  --copy-protection        Enable copy protection in SCUMM games, when\n"
 	"                           ScummVM disables it by default.\n"
 	"  --talkspeed=NUM          Set talk speed for games (default: 60)\n"
-#ifndef DISABLE_SCUMM
+#ifdef ENABLE_SCUMM
 	"  --demo-mode              Start demo mode of Maniac Mansion\n"
 	"  --tempo=NUM              Set music tempo (in percent, 50-200) for SCUMM games\n"
 	"                           (default: 100)\n"
@@ -190,19 +190,19 @@
 	ConfMan.registerDefault("save_slot", -1);
 	ConfMan.registerDefault("autosave_period", 5 * 60);	// By default, trigger autosave every 5 minutes
 
-#if !defined(DISABLE_SCUMM) || !defined(DISABLE_SWORD2)
+#if defined(ENABLE_SCUMM) || defined(ENABLE_SWORD2)
 	ConfMan.registerDefault("object_labels", true);
 #endif
 
 	ConfMan.registerDefault("copy_protection", false);
 	ConfMan.registerDefault("talkspeed", 60);
 
-#ifndef DISABLE_SCUMM
+#ifdef ENABLE_SCUMM
 	ConfMan.registerDefault("demo_mode", false);
 	ConfMan.registerDefault("tempo", 0);
 #endif
 
-#if !defined(DISABLE_SKY) || !defined(DISABLE_QUEEN)
+#if defined(ENABLE_SKY) || defined(ENABLE_QUEEN)
 	ConfMan.registerDefault("alt_intro", false);
 #endif
 
@@ -513,7 +513,7 @@
 			DO_LONG_OPTION("target-md5")
 			END_OPTION
 
-#ifndef DISABLE_SCUMM
+#ifdef ENABLE_SCUMM
 			DO_LONG_OPTION_INT("tempo")
 			END_OPTION
 
@@ -521,7 +521,7 @@
 			END_OPTION
 #endif
 
-#if !defined(DISABLE_SKY) || !defined(DISABLE_QUEEN)
+#if defined(ENABLE_SKY) || defined(ENABLE_QUEEN)
 			DO_LONG_OPTION_BOOL("alt-intro")
 			END_OPTION
 #endif

Modified: scummvm/trunk/base/plugins.cpp
===================================================================
--- scummvm/trunk/base/plugins.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/base/plugins.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -63,7 +63,6 @@
 }
 
 
-#ifndef DYNAMIC_MODULES
 class StaticPlugin : public Plugin {
 public:
 	StaticPlugin(PluginObject *pluginobject, PluginType type) {
@@ -100,61 +99,61 @@
 		// "Loader" for the static plugins.
 		// Iterate over all registered (static) plugins and load them.
 
-		#ifndef DISABLE_SCUMM
+		#if PLUGIN_ENABLED_STATIC(SCUMM)
 		LINK_PLUGIN(SCUMM)
 		#endif
-		#ifndef DISABLE_AGI
+		#if PLUGIN_ENABLED_STATIC(AGI)
 		LINK_PLUGIN(AGI)
 		#endif
-		#ifndef DISABLE_AGOS
+		#if PLUGIN_ENABLED_STATIC(AGOS)
 		LINK_PLUGIN(AGOS)
 		#endif
-		#ifndef DISABLE_CINE
+		#if PLUGIN_ENABLED_STATIC(CINE)
 		LINK_PLUGIN(CINE)
 		#endif
-		#ifndef DISABLE_CRUISE
+		#if PLUGIN_ENABLED_STATIC(CRUISE)
 		LINK_PLUGIN(CRUISE)
 		#endif
-		#ifndef DISABLE_DRASCULA
+		#if PLUGIN_ENABLED_STATIC(DRASCULA)
 		LINK_PLUGIN(DRASCULA)
 		#endif
-		#ifndef DISABLE_GOB
+		#if PLUGIN_ENABLED_STATIC(GOB)
 		LINK_PLUGIN(GOB)
 		#endif
-		#ifndef DISABLE_IGOR
+		#if PLUGIN_ENABLED_STATIC(IGOR)
 		LINK_PLUGIN(IGOR)
 		#endif
-		#ifndef DISABLE_KYRA
+		#if PLUGIN_ENABLED_STATIC(KYRA)
 		LINK_PLUGIN(KYRA)
 		#endif
-		#ifndef DISABLE_LURE
+		#if PLUGIN_ENABLED_STATIC(LURE)
 		LINK_PLUGIN(LURE)
 		#endif
-		#ifndef DISABLE_M4
+		#if PLUGIN_ENABLED_STATIC(M4)
 		LINK_PLUGIN(M4)
 		#endif
-		#ifndef DISABLE_MADE
+		#if PLUGIN_ENABLED_STATIC(MADE)
 		LINK_PLUGIN(MADE)
 		#endif		
-		#ifndef DISABLE_PARALLACTION
+		#if PLUGIN_ENABLED_STATIC(PARALLACTION)
 		LINK_PLUGIN(PARALLACTION)
 		#endif
-		#ifndef DISABLE_QUEEN
+		#if PLUGIN_ENABLED_STATIC(QUEEN)
 		LINK_PLUGIN(QUEEN)
 		#endif
-		#ifndef DISABLE_SAGA
+		#if PLUGIN_ENABLED_STATIC(SAGA)
 		LINK_PLUGIN(SAGA)
 		#endif
-		#ifndef DISABLE_SKY
+		#if PLUGIN_ENABLED_STATIC(SKY)
 		LINK_PLUGIN(SKY)
 		#endif
-		#ifndef DISABLE_SWORD1
+		#if PLUGIN_ENABLED_STATIC(SWORD1)
 		LINK_PLUGIN(SWORD1)
 		#endif
-		#ifndef DISABLE_SWORD2
+		#if PLUGIN_ENABLED_STATIC(SWORD2)
 		LINK_PLUGIN(SWORD2)
 		#endif
-		#ifndef DISABLE_TOUCHE
+		#if PLUGIN_ENABLED_STATIC(TOUCHE)
 		LINK_PLUGIN(TOUCHE)
 		#endif
 
@@ -162,7 +161,7 @@
 	}
 };
 
-#else
+#ifdef DYNAMIC_MODULES
 
 PluginList FilePluginProvider::getPlugins() {
 	PluginList pl;
@@ -222,18 +221,15 @@
 #endif
 }
 
-#endif
+#endif // DYNAMIC_MODULES
 
 #pragma mark -
 
 DECLARE_SINGLETON(PluginManager);
 
 PluginManager::PluginManager() {
-#ifndef DYNAMIC_MODULES
-	// Add the static plugin provider if we do not build with dynamic
-	// plugins.
+	// Always add the static plugin provider.
 	addPluginProvider(new StaticPluginProvider());
-#endif
 }
 
 PluginManager::~PluginManager() {

Modified: scummvm/trunk/base/plugins.h
===================================================================
--- scummvm/trunk/base/plugins.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/base/plugins.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -100,6 +100,15 @@
 };
 
 
+#define STATIC_PLUGIN 1
+#define DYNAMIC_PLUGIN 2
+
+#define PLUGIN_ENABLED_STATIC(ID) \
+	(defined(ENABLE_##ID) && !PLUGIN_ENABLED_DYNAMIC(ID))
+
+#define PLUGIN_ENABLED_DYNAMIC(ID) \
+	(defined(ENABLE_##ID) && (ENABLE_##ID == DYNAMIC_PLUGIN) && defined(DYNAMIC_MODULES))
+
 /**
  * REGISTER_PLUGIN is a convenience macro meant to ease writing
  * the plugin interface for our modules. In particular, using it
@@ -109,15 +118,16 @@
  * @todo	add some means to query the plugin API version etc.
  */
 
-#ifndef DYNAMIC_MODULES
-#define REGISTER_PLUGIN(ID,TYPE,PLUGINCLASS) \
+#define REGISTER_PLUGIN_STATIC(ID,TYPE,PLUGINCLASS) \
 	PluginType g_##ID##_type = TYPE; \
 	PluginObject *g_##ID##_getObject() { \
 		return new PLUGINCLASS(); \
 	} \
 	void dummyFuncToAllowTrailingSemicolon()
-#else
-#define REGISTER_PLUGIN(ID,TYPE,PLUGINCLASS) \
+
+#ifdef DYNAMIC_MODULES
+
+#define REGISTER_PLUGIN_DYNAMIC(ID,TYPE,PLUGINCLASS) \
 	extern "C" { \
 		PLUGIN_EXPORT int32 PLUGIN_getVersion() { return PLUGIN_VERSION; } \
 		PLUGIN_EXPORT int32 PLUGIN_getType() { return TYPE; } \
@@ -127,9 +137,10 @@
 		} \
 	} \
 	void dummyFuncToAllowTrailingSemicolon()
-#endif
 
+#endif // DYNAMIC_MODULES
 
+
 /** List of plugins. */
 typedef Common::Array<Plugin *> PluginList;
 

Modified: scummvm/trunk/configure
===================================================================
--- scummvm/trunk/configure	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/configure	2008-05-06 03:00:26 UTC (rev 31888)
@@ -106,6 +106,7 @@
 _need_memalign=no
 _have_x86=no
 _build_plugins=no
+_plugins_default=static
 _nasm=auto
 
 # more defaults
@@ -363,21 +364,33 @@
 
 # Enable the given engine
 engine_enable() {
-	engine=`echo $1 | sed 's/-/_/g'`
-	if test "`get_engine_build ${engine}`" = "no" ; then
-		eval _engine_${engine}_build=yes
+	# Get the parameter
+	if ( echo $1 | grep '=' ) 2> /dev/null > /dev/null ; then
+		eng=`echo $1 | cut -d '=' -f 1`
+		opt=`echo $1 | cut -d '=' -f 2`
 	else
-		option_error --enable-$1
+		eng=$1
+		opt=yes
 	fi
+	engine=`echo $eng | sed 's/-/_/g'`
+	if test "$opt" == "static" -o "$opt" == "dynamic" -o "$opt" == "yes" ; then
+		if test "`get_engine_build ${engine}`" != "$opt" ; then
+			eval _engine_${engine}_build=$opt
+		else
+			option_error
+		fi
+	else
+		option_error
+	fi
 }
 
 # Disable the given engine
 engine_disable() {
 	engine=`echo $1 | sed 's/-/_/g'`
-	if test "`get_engine_build $engine`" = "yes" ; then
+	if test "`get_engine_build $engine`" != "no" ; then
 		eval _engine_${engine}_build=no
 	else
-		option_error --disable-$1
+		option_error
 	fi
 }
 
@@ -420,27 +433,35 @@
 
 # Prepare the strings about the engines to build
 prepare_engine_build_strings() {
-	string_yes=`get_engine_build_string $1 yes`
-	if test -n "$string_yes" ; then
-		_engines_built="${_engines_built}#$string_yes@"
+	string=`get_engine_build_string $1 static`
+	if test -n "$string" ; then
+		_engines_built_static="${_engines_built_static}#$string@"
 	fi
 
-	string_no=`get_engine_build_string $1 no`
-	if test -n "$string_no" ; then
-		_engines_skipped="${_engines_skipped}#$string_no@"
+	string=`get_engine_build_string $1 dynamic`
+	if test -n "$string" ; then
+		_engines_built_dynamic="${_engines_built_dynamic}#$string@"
 	fi
+
+	string=`get_engine_build_string $1 no`
+	if test -n "$string" ; then
+		_engines_skipped="${_engines_skipped}#$string@"
+	fi
 }
 
 # Get the string about building an engine
 get_engine_build_string() {
 	engine_string=""
-	if test `get_engine_build $1` = no ; then
+	engine_build=`get_engine_build $1`
+	if test $engine_build = no ; then
+		# The engine is disabled
 		if test $2 = no ; then
 			engine_string=`get_engine_name $1`
 		else
 			engine_string=""
 		fi
 	else
+		# The engine is enabled, get the custom string
 		build_string_func=get_${1}_build_string
 		if ( type $build_string_func | grep function ) 2> /dev/null > /dev/null ; then
 			engine_string=`$build_string_func $1 $2`
@@ -448,12 +469,16 @@
 			engine_string=`get_subengines_build_string $1 $2`
 		fi
 
-		if test $2 = yes ; then
-			engine_string="`get_engine_name $1` $engine_string"
-		else
+		if test $2 = no ; then
 			if test -n "$engine_string" ; then
 				engine_string="`get_engine_name $1` $engine_string"
 			fi
+		else
+			if test $2 = $engine_build ; then
+				engine_string="`get_engine_name $1` $engine_string"
+			else
+				engine_string=""
+			fi
 		fi
 	fi
 
@@ -471,7 +496,7 @@
 			all=no
 		fi
 	done
-	if test $2 = yes ; then
+	if test $2 != no ; then
 		if test -n "$subengine_string" ; then
 			if test $all = yes ; then
 				subengine_string="[all games]"
@@ -484,7 +509,7 @@
 
 # Engine specific build strings
 get_sword1_build_string() {
-	if test $2 = yes ; then
+	if test $2 != no ; then
 		if test "$_mpeg2" = yes ; then
 			echo "(w/ mpeg2 cutscenes)"
 		else
@@ -498,7 +523,7 @@
 }
 
 get_scumm_build_string() {
-	if test $2 = yes ; then
+	if test $2 != no ; then
 		base="[v0-v6 games]"
 	fi
 	get_subengines_build_string $1 $2 "$base"
@@ -551,8 +576,8 @@
   --disable-debug          disable building with debugging symbols
   --enable-Werror          treat warnings as errors
 $engines_help
-  --enable-plugins         build engines as loadable modules instead of
-                           static linking them
+  --enable-plugins         enable the support for dynamic plugins
+  --default-dynamic        make plugins dynamic by default
   --disable-mt32emu        don't enable the integrated MT-32 emulator
   --disable-hq-scalers     exclude HQ2x and HQ3x scalers
   --disable-scalers        exclude scalers
@@ -630,6 +655,7 @@
 	--disable-mpeg2)          _mpeg2=no       ;;
 	--disable-fluidsynth)     _fluidsynth=no  ;;
 	--enable-plugins)         _build_plugins=yes ;;
+	--default-dynamic)        _plugins_default=dynamic ;;
 	--enable-mt32emu)         _mt32emu=yes    ;;
 	--disable-mt32emu)        _mt32emu=no     ;;
 	--with-fluidsynth-prefix=*)
@@ -725,7 +751,7 @@
 		engine_disable `echo $ac_option | cut -d '-' -f 4-`
 		;;
 	*)
-		option_error $ac_option
+		option_error
 		;;
 	esac;
 done;
@@ -897,12 +923,6 @@
 	add_line_to_config_mk 'HAVE_GCC3 = 1'
 fi;
 
-#
-# Engine selection
-#
-for engine in $_engines; do
-	add_to_config_mk_if_no `get_engine_build $engine` "DISABLE_`echo $engine | tr [a-z] [A-Z]` = 1"
-done
 add_to_config_mk_if_no $_build_hq_scalers   'DISABLE_HQ_SCALERS = 1'
 add_to_config_mk_if_no $_build_scalers      'DISABLE_SCALERS = 1'
 
@@ -1532,26 +1552,77 @@
 
 
 #
-# Show which engines ("frontends") are to be built
+# Engine selection
 #
-
-_engines_built=""
+_engines_built_static=""
+_engines_built_dynamic=""
 _engines_skipped=""
 
 for engine in $_engines; do
 	if test "`get_engine_sub $engine`" = "no" ; then
+		# It's a main engine
+		if test `get_engine_build $engine` = no ; then
+			isbuilt=no
+		else
+			# If dynamic plugins aren't supported, mark
+			# all the engines as static
+			if test $_build_plugins = no ; then
+				eval _engine_${engine}_build=static
+			else
+				# If it wasn't explicitly marked as static or
+				# dynamic, use the configured default
+				if test `get_engine_build $engine` = yes ; then
+					eval _engine_${engine}_build=${_plugins_default}
+				fi
+			fi
+
+			# Prepare the defines
+			if test `get_engine_build $engine` = dynamic ; then
+				isbuilt=DYNAMIC_PLUGIN
+			else
+				eval _engine_${engine}_build=static
+				isbuilt=STATIC_PLUGIN
+			fi
+		fi
+
+		# Prepare the information to be shown
 		prepare_engine_build_strings $engine
+	else
+		# It's a subengine, just say yes or no
+		if test "`get_engine_build $engine`" = "no" ; then
+			isbuilt=no
+		else
+			isbuilt=1
+		fi
 	fi
+
+	# Save the settings
+	defname="ENABLE_`echo $engine | tr [a-z] [A-Z]`"
+	if test "$isbuilt" = "no" ; then
+		add_line_to_config_mk "# $defname"
+	else
+		add_line_to_config_mk "$defname = $isbuilt"
+	fi
 done
 
+#
+# Show which engines ("frontends") are to be built
+#
 echo
-if test -n "$_engines_built" ; then
-	echo "Engines:"
-	echo $_engines_built | sed 's/@/\
+if test -n "$_engines_built_static" ; then
+	echo "Engines (builtin):"
+	echo $_engines_built_static | sed 's/@/\
 /g
 s/#/    /g'
 fi
 
+if test -n "$_engines_built_dynamic" ; then
+	echo "Engines (plugins):"
+	echo $_engines_built_dynamic | sed 's/@/\
+/g
+s/#/    /g'
+fi
+
 if test -n "$_engines_skipped" ; then
 	echo "Engines Skipped:"
 	echo $_engines_skipped | sed 's/@/\

Modified: scummvm/trunk/engines/agi/detection.cpp
===================================================================
--- scummvm/trunk/engines/agi/detection.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/agi/detection.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -2324,4 +2324,8 @@
 	return 0;
 }
 
-REGISTER_PLUGIN(AGI, PLUGIN_TYPE_ENGINE, AgiMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(AGI)
+	REGISTER_PLUGIN_DYNAMIC(AGI, PLUGIN_TYPE_ENGINE, AgiMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(AGI, PLUGIN_TYPE_ENGINE, AgiMetaEngine);
+#endif

Modified: scummvm/trunk/engines/agi/module.mk
===================================================================
--- scummvm/trunk/engines/agi/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/agi/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -38,7 +38,7 @@
 
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_AGI), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/agos/detection.cpp
===================================================================
--- scummvm/trunk/engines/agos/detection.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/agos/detection.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -149,7 +149,11 @@
 	return res;
 }
 
-REGISTER_PLUGIN(AGOS, PLUGIN_TYPE_ENGINE, AgosMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(AGOS)
+	REGISTER_PLUGIN_DYNAMIC(AGOS, PLUGIN_TYPE_ENGINE, AgosMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(AGOS, PLUGIN_TYPE_ENGINE, AgosMetaEngine);
+#endif
 
 namespace AGOS {
 

Modified: scummvm/trunk/engines/agos/module.mk
===================================================================
--- scummvm/trunk/engines/agos/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/agos/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -47,7 +47,7 @@
 	zones.o
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_AGOS), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/cine/detection.cpp
===================================================================
--- scummvm/trunk/engines/cine/detection.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/cine/detection.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -509,4 +509,8 @@
 	return gd != 0;
 }
 
-REGISTER_PLUGIN(CINE, PLUGIN_TYPE_ENGINE, CineMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(CINE)
+	REGISTER_PLUGIN_DYNAMIC(CINE, PLUGIN_TYPE_ENGINE, CineMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(CINE, PLUGIN_TYPE_ENGINE, CineMetaEngine);
+#endif

Modified: scummvm/trunk/engines/cine/module.mk
===================================================================
--- scummvm/trunk/engines/cine/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/cine/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -22,7 +22,7 @@
 	various.o
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_CINE), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/cruise/detection.cpp
===================================================================
--- scummvm/trunk/engines/cruise/detection.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/cruise/detection.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -144,4 +144,8 @@
 	return gd != 0;
 }
 
-REGISTER_PLUGIN(CRUISE, PLUGIN_TYPE_ENGINE, CruiseMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(CRUISE)
+	REGISTER_PLUGIN_DYNAMIC(CRUISE, PLUGIN_TYPE_ENGINE, CruiseMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(CRUISE, PLUGIN_TYPE_ENGINE, CruiseMetaEngine);
+#endif

Modified: scummvm/trunk/engines/cruise/module.mk
===================================================================
--- scummvm/trunk/engines/cruise/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/cruise/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -33,7 +33,7 @@
 	volume.o
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_CRUISE), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/drascula/detection.cpp
===================================================================
--- scummvm/trunk/engines/drascula/detection.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/drascula/detection.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -185,4 +185,8 @@
 	return (const Common::ADGameDescription *)&Drascula::g_fallbackDesc;
 }
 
-REGISTER_PLUGIN(DRASCULA, PLUGIN_TYPE_ENGINE, DrasculaMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(DRASCULA)
+	REGISTER_PLUGIN_DYNAMIC(DRASCULA, PLUGIN_TYPE_ENGINE, DrasculaMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(DRASCULA, PLUGIN_TYPE_ENGINE, DrasculaMetaEngine);
+#endif

Modified: scummvm/trunk/engines/drascula/module.mk
===================================================================
--- scummvm/trunk/engines/drascula/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/drascula/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -10,7 +10,7 @@
 
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_DRASCULA), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/engines.mk
===================================================================
--- scummvm/trunk/engines/engines.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/engines.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -1,122 +1,103 @@
-ifdef DISABLE_SCUMM
-DEFINES += -DDISABLE_SCUMM
-else
+ifdef ENABLE_SCUMM
+DEFINES += -DENABLE_SCUMM=$(ENABLE_SCUMM)
 MODULES += engines/scumm
 
-ifdef DISABLE_SCUMM_7_8
-DEFINES += -DDISABLE_SCUMM_7_8
+ifdef ENABLE_SCUMM_7_8
+DEFINES += -DENABLE_SCUMM_7_8
 endif
 
-ifdef DISABLE_HE
-DEFINES += -DDISABLE_HE
+ifdef ENABLE_HE
+DEFINES += -DENABLE_HE
 endif
 
 endif
 
-ifdef DISABLE_AGI
-DEFINES += -DDISABLE_AGI
-else
+ifdef ENABLE_AGI
+DEFINES += -DENABLE_AGI=$(ENABLE_AGI)
 MODULES += engines/agi
 endif
 
-ifdef DISABLE_AGOS
-DEFINES += -DDISABLE_AGOS
-else
+ifdef ENABLE_AGOS
+DEFINES += -DENABLE_AGOS=$(ENABLE_AGOS)
 MODULES += engines/agos
 endif
 
-ifdef DISABLE_CINE
-DEFINES += -DDISABLE_CINE
-else
+ifdef ENABLE_CINE
+DEFINES += -DENABLE_CINE=$(ENABLE_CINE)
 MODULES += engines/cine
 endif
 
-ifdef DISABLE_CRUISE
-DEFINES += -DDISABLE_CRUISE
-else
+ifdef ENABLE_CRUISE
+DEFINES += -DENABLE_CRUISE=$(ENABLE_CRUISE)
 MODULES += engines/cruise
 endif
 
-ifdef DISABLE_DRASCULA
-DEFINES += -DDISABLE_DRASCULA
-else
+ifdef ENABLE_DRASCULA
+DEFINES += -DENABLE_DRASCULA=$(ENABLE_DRASCULA)
 MODULES += engines/drascula
 endif
 
-ifdef DISABLE_GOB
-DEFINES += -DDISABLE_GOB
-else
+ifdef ENABLE_GOB
+DEFINES += -DENABLE_GOB=$(ENABLE_GOB)
 MODULES += engines/gob
 endif
 
-ifdef DISABLE_IGOR
-DEFINES += -DDISABLE_IGOR
-else
+ifdef ENABLE_IGOR
+DEFINES += -DENABLE_IGOR=$(ENABLE_IGOR)
 MODULES += engines/igor
 endif
 
-ifdef DISABLE_KYRA
-DEFINES += -DDISABLE_KYRA
-else
+ifdef ENABLE_KYRA
+DEFINES += -DENABLE_KYRA=$(ENABLE_KYRA)
 MODULES += engines/kyra
 endif
 
-ifdef DISABLE_LURE
-DEFINES += -DDISABLE_LURE
-else
+ifdef ENABLE_LURE
+DEFINES += -DENABLE_LURE=$(ENABLE_LURE)
 MODULES += engines/lure
 endif
 
-ifdef DISABLE_M4
-DEFINES += -DDISABLE_M4
-else
+ifdef ENABLE_M4
+DEFINES += -DENABLE_M4=$(ENABLE_M4)
 MODULES += engines/m4
 endif
 
-ifdef DISABLE_MADE
-DEFINES += -DDISABLE_MADE
-else
+ifdef ENABLE_MADE
+DEFINES += -DENABLE_MADE=$(ENABLE_MADE)
 MODULES += engines/made
 endif
 
-ifdef DISABLE_PARALLACTION
-DEFINES += -DDISABLE_PARALLACTION
-else
+ifdef ENABLE_PARALLACTION
+DEFINES += -DENABLE_PARALLACTION=$(ENABLE_PARALLACTION)
 MODULES += engines/parallaction
 endif
 
-ifdef DISABLE_QUEEN
-DEFINES += -DDISABLE_QUEEN
-else
+ifdef ENABLE_QUEEN
+DEFINES += -DENABLE_QUEEN=$(ENABLE_QUEEN)
 MODULES += engines/queen
 endif
 
-ifdef DISABLE_SAGA
-DEFINES += -DDISABLE_SAGA
-else
+ifdef ENABLE_SAGA
+DEFINES += -DENABLE_SAGA=$(ENABLE_SAGA)
 MODULES += engines/saga
 endif
 
-ifdef DISABLE_SKY
-DEFINES += -DDISABLE_SKY
-else
+ifdef ENABLE_SKY
+DEFINES += -DENABLE_SKY=$(ENABLE_SKY)
 MODULES += engines/sky
 endif
 
-ifdef DISABLE_SWORD1
-DEFINES += -DDISABLE_SWORD1
-else
+ifdef ENABLE_SWORD1
+DEFINES += -DENABLE_SWORD1=$(ENABLE_SWORD1)
 MODULES += engines/sword1
 endif
 
-ifdef DISABLE_SWORD2
-DEFINES += -DDISABLE_SWORD2
-else
+ifdef ENABLE_SWORD2
+DEFINES += -DENABLE_SWORD2=$(ENABLE_SWORD2)
 MODULES += engines/sword2
 endif
 
-ifdef DISABLE_TOUCHE
-DEFINES += -DDISABLE_TOUCHE
-else
+ifdef ENABLE_TOUCHE
+DEFINES += -DENABLE_TOUCHE=$(ENABLE_TOUCHE)
 MODULES += engines/touche
 endif

Modified: scummvm/trunk/engines/gob/detection.cpp
===================================================================
--- scummvm/trunk/engines/gob/detection.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/gob/detection.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -1907,7 +1907,11 @@
 	return gd != 0;
 }
 
-REGISTER_PLUGIN(GOB, PLUGIN_TYPE_ENGINE, GobMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(GOB)
+	REGISTER_PLUGIN_DYNAMIC(GOB, PLUGIN_TYPE_ENGINE, GobMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(GOB, PLUGIN_TYPE_ENGINE, GobMetaEngine);
+#endif
 
 namespace Gob {
 

Modified: scummvm/trunk/engines/gob/module.mk
===================================================================
--- scummvm/trunk/engines/gob/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/gob/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -56,7 +56,7 @@
 	video_v2.o
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_GOB), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/igor/detection.cpp
===================================================================
--- scummvm/trunk/engines/igor/detection.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/igor/detection.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -133,4 +133,8 @@
 	return gd != 0;
 }
 
-REGISTER_PLUGIN(IGOR, PLUGIN_TYPE_ENGINE, IgorMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(IGOR)
+	REGISTER_PLUGIN_DYNAMIC(IGOR, PLUGIN_TYPE_ENGINE, IgorMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(IGOR, PLUGIN_TYPE_ENGINE, IgorMetaEngine);
+#endif

Modified: scummvm/trunk/engines/igor/module.mk
===================================================================
--- scummvm/trunk/engines/igor/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/igor/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -38,7 +38,7 @@
 	parts/part_main.o
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_IGOR), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/kyra/detection.cpp
===================================================================
--- scummvm/trunk/engines/kyra/detection.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/kyra/detection.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -550,4 +550,8 @@
 	return saveList;
 }
 
-REGISTER_PLUGIN(KYRA, PLUGIN_TYPE_ENGINE, KyraMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(KYRA)
+	REGISTER_PLUGIN_DYNAMIC(KYRA, PLUGIN_TYPE_ENGINE, KyraMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(KYRA, PLUGIN_TYPE_ENGINE, KyraMetaEngine);
+#endif

Modified: scummvm/trunk/engines/kyra/module.mk
===================================================================
--- scummvm/trunk/engines/kyra/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/kyra/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -66,7 +66,7 @@
 	wsamovie.o
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_KYRA), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/lure/detection.cpp
===================================================================
--- scummvm/trunk/engines/lure/detection.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/lure/detection.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -195,4 +195,8 @@
 	return gd != 0;
 }
 
-REGISTER_PLUGIN(LURE, PLUGIN_TYPE_ENGINE, LureMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(LURE)
+	REGISTER_PLUGIN_DYNAMIC(LURE, PLUGIN_TYPE_ENGINE, LureMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(LURE, PLUGIN_TYPE_ENGINE, LureMetaEngine);
+#endif

Modified: scummvm/trunk/engines/lure/module.mk
===================================================================
--- scummvm/trunk/engines/lure/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/lure/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -25,7 +25,7 @@
 	surface.o
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_LURE), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/m4/detection.cpp
===================================================================
--- scummvm/trunk/engines/m4/detection.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/m4/detection.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -387,4 +387,8 @@
 	return gd != 0;
 }
 
-REGISTER_PLUGIN(M4, PLUGIN_TYPE_ENGINE, M4MetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(M4)
+	REGISTER_PLUGIN_DYNAMIC(M4, PLUGIN_TYPE_ENGINE, M4MetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(M4, PLUGIN_TYPE_ENGINE, M4MetaEngine);
+#endif

Modified: scummvm/trunk/engines/m4/module.mk
===================================================================
--- scummvm/trunk/engines/m4/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/m4/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -34,7 +34,7 @@
 
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_M4), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/made/detection.cpp
===================================================================
--- scummvm/trunk/engines/made/detection.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/made/detection.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -271,4 +271,8 @@
 	return (const Common::ADGameDescription *)&Made::g_fallbackDesc;
 }
 
-REGISTER_PLUGIN(MADE, PLUGIN_TYPE_ENGINE, MadeMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(MADE)
+	REGISTER_PLUGIN_DYNAMIC(MADE, PLUGIN_TYPE_ENGINE, MadeMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(MADE, PLUGIN_TYPE_ENGINE, MadeMetaEngine);
+#endif

Modified: scummvm/trunk/engines/made/module.mk
===================================================================
--- scummvm/trunk/engines/made/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/made/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -18,7 +18,7 @@
 
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_MADE), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/parallaction/detection.cpp
===================================================================
--- scummvm/trunk/engines/parallaction/detection.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/parallaction/detection.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -233,4 +233,8 @@
 	return res;
 }
 
-REGISTER_PLUGIN(PARALLACTION, PLUGIN_TYPE_ENGINE, ParallactionMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(PARALLACTION)
+	REGISTER_PLUGIN_DYNAMIC(PARALLACTION, PLUGIN_TYPE_ENGINE, ParallactionMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(PARALLACTION, PLUGIN_TYPE_ENGINE, ParallactionMetaEngine);
+#endif

Modified: scummvm/trunk/engines/parallaction/module.mk
===================================================================
--- scummvm/trunk/engines/parallaction/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/parallaction/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -29,7 +29,7 @@
 	walk.o
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_PARALLACTION), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/queen/module.mk
===================================================================
--- scummvm/trunk/engines/queen/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/queen/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -24,7 +24,7 @@
 	walk.o
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_QUEEN), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/queen/queen.cpp
===================================================================
--- scummvm/trunk/engines/queen/queen.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/queen/queen.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -127,7 +127,11 @@
 	return kNoError;
 }
 
-REGISTER_PLUGIN(QUEEN, PLUGIN_TYPE_ENGINE, QueenMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(QUEEN)
+	REGISTER_PLUGIN_DYNAMIC(QUEEN, PLUGIN_TYPE_ENGINE, QueenMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(QUEEN, PLUGIN_TYPE_ENGINE, QueenMetaEngine);
+#endif
 
 namespace Queen {
 

Modified: scummvm/trunk/engines/saga/detection.cpp
===================================================================
--- scummvm/trunk/engines/saga/detection.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/saga/detection.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -162,7 +162,11 @@
 	return gd != 0;
 }
 
-REGISTER_PLUGIN(SAGA, PLUGIN_TYPE_ENGINE, SagaMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(SAGA)
+	REGISTER_PLUGIN_DYNAMIC(SAGA, PLUGIN_TYPE_ENGINE, SagaMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(SAGA, PLUGIN_TYPE_ENGINE, SagaMetaEngine);
+#endif
 
 namespace Saga {
 

Modified: scummvm/trunk/engines/saga/module.mk
===================================================================
--- scummvm/trunk/engines/saga/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/saga/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -35,7 +35,7 @@
 	sound.o
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_SAGA), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/scumm/actor.cpp
===================================================================
--- scummvm/trunk/engines/scumm/actor.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/actor.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -902,7 +902,7 @@
 			}
 			adjustActorPos();
 		} else {
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 			if (_vm->_game.heversion >= 71)
 				((ScummEngine_v71he *)_vm)->queueAuxBlock(this);
 #endif
@@ -1379,7 +1379,7 @@
 		akos_processQueue();
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 void ScummEngine_v71he::processActors() {
 	preProcessAuxQueue();
 
@@ -1543,7 +1543,7 @@
 	}
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 bool Actor::actorHitTest(int x, int y) {
 	AkosRenderer *ar = (AkosRenderer *)_vm->_costumeRenderer;
 
@@ -1681,7 +1681,7 @@
 	}
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void Actor::animateLimb(int limb, int f) {
 	// This methods is very similiar to animateCostume().
 	// However, instead of animating *all* the limbs, it only animates
@@ -1853,7 +1853,7 @@
 	}
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v7::actorTalk(const byte *msg) {
 	Actor *a;
 	bool stringWrap = false;
@@ -2021,7 +2021,7 @@
 
 	_keepText = false;
 	if (_game.version >= 7) {
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 		((ScummEngine_v7 *)this)->clearSubtitleQueue();
 #endif
 	} else {
@@ -2054,7 +2054,7 @@
 	if (_vm->_game.features & GF_NEW_COSTUMES) {
 		memset(_animVariable, 0, sizeof(_animVariable));
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 		if (_vm->_game.heversion >= 71)
 			((ScummEngine_v71he *)_vm)->queueAuxBlock(this);
 #endif
@@ -2293,7 +2293,7 @@
 	return (_heCondMask & (1 << (slot - 1))) != 0;
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 void ScummEngine_v71he::preProcessAuxQueue() {
 	if (!_skipProcessActors) {
 		for (int i = 0; i < _auxBlocksNum; ++i) {

Modified: scummvm/trunk/engines/scumm/akos.cpp
===================================================================
--- scummvm/trunk/engines/scumm/akos.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/akos.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -1272,7 +1272,7 @@
 }
 
 byte AkosRenderer::codec32(int xmoveCur, int ymoveCur) {
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 	Common::Rect src, dst;
 
 	if (!_mirror) {
@@ -1767,7 +1767,7 @@
 			a->_offsY = param_2;
 			break;
 		case 7:
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 			assert(_game.heversion >= 71);
 			((ScummEngine_v71he *)this)->queueAuxEntry(a->_number, param_1);
 #endif
@@ -1793,7 +1793,7 @@
 	}
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v7::akos_processQueue() {
 	byte cmd;
 	int actor, param_1, param_2;

Modified: scummvm/trunk/engines/scumm/camera.cpp
===================================================================
--- scummvm/trunk/engines/scumm/camera.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/camera.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -221,7 +221,7 @@
 	}
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v7::setCameraAt(int pos_x, int pos_y) {
 	Common::Point old;
 

Modified: scummvm/trunk/engines/scumm/charset.cpp
===================================================================
--- scummvm/trunk/engines/scumm/charset.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/charset.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -795,7 +795,7 @@
 	int drawTop = _top - vs->topline;
 
 	if ((_vm->_game.heversion >= 71 && _bitDepth >= 8) || (_vm->_game.heversion >= 90 && _bitDepth == 0)) {
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 		if (ignoreCharsetMask || !vs->hasTwoBuffers) {
 			dstPtr = vs->getPixels(0, 0);
 		} else {
@@ -971,7 +971,7 @@
 	}
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 CharsetRendererNut::CharsetRendererNut(ScummEngine *vm)
 	 : CharsetRenderer(vm) {
 	_current = 0;

Modified: scummvm/trunk/engines/scumm/charset.h
===================================================================
--- scummvm/trunk/engines/scumm/charset.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/charset.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -172,7 +172,7 @@
 	int getCharWidth(byte chr) { return 8; }
 };
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 class CharsetRendererNut : public CharsetRenderer {
 protected:
 	NutRenderer *_fr[5];

Modified: scummvm/trunk/engines/scumm/detection.cpp
===================================================================
--- scummvm/trunk/engines/scumm/detection.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/detection.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -873,7 +873,7 @@
 		break;
 	case 6:
 		switch (res.game.heversion) {
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 		case 200:
 			*engine = new ScummEngine_vCUPhe(syst, res);
 			break;
@@ -910,7 +910,7 @@
 			*engine = new ScummEngine_v6(syst, res);
 		}
 		break;
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 	case 7:
 		*engine = new ScummEngine_v7(syst, res);
 		break;
@@ -966,4 +966,8 @@
 	return saveList;
 }
 
-REGISTER_PLUGIN(SCUMM, PLUGIN_TYPE_ENGINE, ScummMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(SCUMM)
+	REGISTER_PLUGIN_DYNAMIC(SCUMM, PLUGIN_TYPE_ENGINE, ScummMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(SCUMM, PLUGIN_TYPE_ENGINE, ScummMetaEngine);
+#endif

Modified: scummvm/trunk/engines/scumm/detection_tables.h
===================================================================
--- scummvm/trunk/engines/scumm/detection_tables.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/detection_tables.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -67,7 +67,7 @@
 	{ "tentacle", "Day of the Tentacle" },
 	{ "zak", "Zak McKracken and the Alien Mindbenders" },
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 	{ "ft", "Full Throttle" },
 	{ "dig", "The Dig" },
 	{ "comi", "The Curse of Monkey Island" },
@@ -81,7 +81,7 @@
 	{ "puttmoon", "Putt-Putt Goes to the Moon" },
 	{ "puttputt", "Putt-Putt Joins the Parade" },
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 	{ "airport", "Let's Explore the Airport with Buzzy" },
 	{ "arttime", "Blue's Art Time Activities" },
 	{ "balloon", "Putt-Putt and Pep's Balloon-O-Rama" },
@@ -231,7 +231,7 @@
 
 	{"samnmax",  0, 0, GID_SAMNMAX,  6, 0, MDT_ADLIB | MDT_MIDI, GF_USE_KEY, UNK},
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 	{"ft",       0, 0, GID_FT,  7, 0, MDT_NONE, 0, UNK},
 
 	{"dig",      0, 0, GID_DIG, 7, 0, MDT_NONE, 0, UNK},
@@ -259,7 +259,7 @@
 	// they'll override more specific entries that follow later on.
 	{"", "HE 70",   0, GID_HEGAME, 6,  70, MDT_NONE, GF_USE_KEY, UNK},
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 	// HE CUP demos
 	{"", "HE CUP",  0, GID_HECUP,  6, 200, MDT_NONE, 0, UNK},
 
@@ -443,7 +443,7 @@
 	{ "samnmax", "snmidemo.%03d", kGenDiskNum, UNK_LANG, UNK, 0 },
 	{ "samnmax", "sdemo.sm%d", kGenDiskNum, Common::DE_DEU, UNK, 0 },
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 	{ "dig", "dig.la%d", kGenDiskNum, UNK_LANG, UNK, 0 },
 	{ "dig", "The Dig Data", kGenUnchanged, UNK_LANG, Common::kPlatformMacintosh, 0 },
 	{ "dig", "The Dig Demo Data", kGenUnchanged, UNK_LANG, Common::kPlatformMacintosh, "Demo" },
@@ -482,7 +482,7 @@
 	{ "puttputt", "Putt-Putt's Demo", kGenHEMacNoParens, UNK_LANG, Common::kPlatformMacintosh, 0 },
 	{ "puttputt", "Putt-Putt Parade", kGenHEMacNoParens, UNK_LANG, Common::kPlatformMacintosh, 0 },
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 	{ "airport", "airport", kGenHEPC, UNK_LANG, UNK, 0 },
 	{ "airport", "airdemo", kGenHEPC, UNK_LANG, UNK, 0 },
 	{ "airport", "Airport Demo", kGenHEMac, UNK_LANG, Common::kPlatformMacintosh, 0 },

Modified: scummvm/trunk/engines/scumm/gfx.cpp
===================================================================
--- scummvm/trunk/engines/scumm/gfx.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/gfx.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -28,7 +28,7 @@
 #include "scumm/actor.h"
 #include "scumm/charset.h"
 #include "scumm/intern.h"
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 #include "scumm/he/intern_he.h"
 #endif
 #include "scumm/resource.h"
@@ -907,7 +907,7 @@
 	_bgNeedsRedraw = false;
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 void ScummEngine_v71he::redrawBGAreas() {
 	if (camera._cur.x != camera._last.x && _charset->_hasMask)
 		stopTalk();
@@ -1834,7 +1834,7 @@
 	// Do nothing here for V2 games - zplane was already handled.
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 /**
  * Draw a bitmap onto a virtual screen. This is main drawing method for room backgrounds
  * used throughout HE71+ versions.

Modified: scummvm/trunk/engines/scumm/gfx.h
===================================================================
--- scummvm/trunk/engines/scumm/gfx.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/gfx.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -246,7 +246,7 @@
 	void drawBitmap(const byte *ptr, VirtScreen *vs, int x, int y, const int width, const int height,
 	                int stripnr, int numstrip, byte flag);
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 	void drawBMAPBg(const byte *ptr, VirtScreen *vs);
 	void drawBMAPObject(const byte *ptr, VirtScreen *vs, int obj, int x, int y, int w, int h);
 #endif

Modified: scummvm/trunk/engines/scumm/he/cup_player_he.h
===================================================================
--- scummvm/trunk/engines/scumm/he/cup_player_he.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/he/cup_player_he.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -24,7 +24,7 @@
  */
 
 
-#if !defined(SCUMM_HE_CUP_PLAYER_HE_H) && !defined(DISABLE_HE)
+#if !defined(SCUMM_HE_CUP_PLAYER_HE_H) && defined(ENABLE_HE)
 #define SCUMM_HE_CUP_PLAYER_HE_H
 
 #include "common/stream.h"

Modified: scummvm/trunk/engines/scumm/he/floodfill_he.h
===================================================================
--- scummvm/trunk/engines/scumm/he/floodfill_he.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/he/floodfill_he.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -23,7 +23,7 @@
  *
  */
 
-#if !defined(SCUMM_HE_FLOODFILL_HE_H) && !defined(DISABLE_HE)
+#if !defined(SCUMM_HE_FLOODFILL_HE_H) && defined(ENABLE_HE)
 #define SCUMM_HE_FLOODFILL_HE_H
 
 #include "common/rect.h"

Modified: scummvm/trunk/engines/scumm/he/intern_he.h
===================================================================
--- scummvm/trunk/engines/scumm/he/intern_he.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/he/intern_he.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -27,7 +27,7 @@
 #define SCUMM_HE_INTERN_HE_H
 
 #include "scumm/intern.h"
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 #include "scumm/he/floodfill_he.h"
 #include "scumm/he/wiz_he.h"
 #endif
@@ -40,7 +40,7 @@
 namespace Scumm {
 
 class ResExtractor;
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 class LogicHE;
 class MoviePlayer;
 class Sprite;
@@ -178,7 +178,7 @@
 	byte VAR_NUM_SOUND_CHANNELS;
 };
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 class ScummEngine_v71he : public ScummEngine_v70he {
 	friend class Wiz;
 

Modified: scummvm/trunk/engines/scumm/he/logic_he.h
===================================================================
--- scummvm/trunk/engines/scumm/he/logic_he.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/he/logic_he.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -23,7 +23,7 @@
  *
  */
 
-#if !defined(SCUMM_HE_LOGIC_HE_H) && !defined(DISABLE_HE)
+#if !defined(SCUMM_HE_LOGIC_HE_H) && defined(ENABLE_HE)
 #define SCUMM_HE_LOGIC_HE_H
 
 

Modified: scummvm/trunk/engines/scumm/he/resource_he.cpp
===================================================================
--- scummvm/trunk/engines/scumm/he/resource_he.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/he/resource_he.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -1524,7 +1524,7 @@
 #endif
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 void ScummEngine_v99he::readMAXS(int blockSize) {
 	if (blockSize == 52) {
 		debug(0, "ScummEngine_v99he readMAXS: MAXS has blocksize %d", blockSize);

Modified: scummvm/trunk/engines/scumm/he/sprite_he.h
===================================================================
--- scummvm/trunk/engines/scumm/he/sprite_he.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/he/sprite_he.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -23,7 +23,7 @@
  *
  */
 
-#if !defined(SCUMM_HE_SPRITE_HE_H) && !defined(DISABLE_HE)
+#if !defined(SCUMM_HE_SPRITE_HE_H) && defined(ENABLE_HE)
 #define SCUMM_HE_SPRITE_HE_H
 
 namespace Scumm {

Modified: scummvm/trunk/engines/scumm/he/wiz_he.h
===================================================================
--- scummvm/trunk/engines/scumm/he/wiz_he.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/he/wiz_he.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -23,7 +23,7 @@
  *
  */
 
-#if !defined(SCUMM_HE_WIZ_HE_H) && !defined(DISABLE_HE)
+#if !defined(SCUMM_HE_WIZ_HE_H) && defined(ENABLE_HE)
 #define SCUMM_HE_WIZ_HE_H
 
 #include "common/rect.h"

Modified: scummvm/trunk/engines/scumm/imuse_digi/dimuse.h
===================================================================
--- scummvm/trunk/engines/scumm/imuse_digi/dimuse.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/imuse_digi/dimuse.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -22,7 +22,7 @@
  * $Id$
  */
 
-#if !defined(SCUMM_IMUSE_DIGI_H) && !defined(DISABLE_SCUMM_7_8)
+#if !defined(SCUMM_IMUSE_DIGI_H) && defined(ENABLE_SCUMM_7_8)
 #define SCUMM_IMUSE_DIGI_H
 
 #include "common/scummsys.h"

Modified: scummvm/trunk/engines/scumm/imuse_digi/dimuse_tables.h
===================================================================
--- scummvm/trunk/engines/scumm/imuse_digi/dimuse_tables.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/imuse_digi/dimuse_tables.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -22,7 +22,7 @@
  * $Id$
  */
 
-#if !defined(SCUMM_IMUSE_DIGI_TABLES_H) && !defined(DISABLE_SCUMM_7_8)
+#if !defined(SCUMM_IMUSE_DIGI_TABLES_H) && defined(ENABLE_SCUMM_7_8)
 #define SCUMM_IMUSE_DIGI_TABLES_H
 
 #include "common/scummsys.h"

Modified: scummvm/trunk/engines/scumm/imuse_digi/dimuse_track.h
===================================================================
--- scummvm/trunk/engines/scumm/imuse_digi/dimuse_track.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/imuse_digi/dimuse_track.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -22,7 +22,7 @@
  * $Id$
  */
 
-#if !defined(SCUMM_IMUSE_DIGI_TRACK_H) && !defined(DISABLE_SCUMM_7_8)
+#if !defined(SCUMM_IMUSE_DIGI_TRACK_H) && defined(ENABLE_SCUMM_7_8)
 #define SCUMM_IMUSE_DIGI_TRACK_H
 
 #include "common/scummsys.h"

Modified: scummvm/trunk/engines/scumm/input.cpp
===================================================================
--- scummvm/trunk/engines/scumm/input.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/input.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -36,7 +36,7 @@
 #include "scumm/dialogs.h"
 #include "scumm/insane/insane.h"
 #include "scumm/imuse/imuse.h"
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 #include "scumm/he/intern_he.h"
 #include "scumm/he/logic_he.h"
 #endif
@@ -202,7 +202,7 @@
 	}
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 void ScummEngine_v90he::clearClickedStatus() {
 	ScummEngine::clearClickedStatus();
 	if (_game.heversion >= 98) {
@@ -328,7 +328,7 @@
 	processKeyboard(lastKeyHit);
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v8::processKeyboard(Common::KeyState lastKeyHit) {
 
 	if (!(_game.features & GF_DEMO)) {

Modified: scummvm/trunk/engines/scumm/insane/insane.h
===================================================================
--- scummvm/trunk/engines/scumm/insane/insane.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/insane/insane.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -23,7 +23,7 @@
  *
  */
 
-#if !defined(SCUMM_INSANE_H) && !defined(DISABLE_SCUMM_7_8)
+#if !defined(SCUMM_INSANE_H) && defined(ENABLE_SCUMM_7_8)
 #define SCUMM_INSANE_H
 
 #include "engines/engine.h"

Modified: scummvm/trunk/engines/scumm/intern.h
===================================================================
--- scummvm/trunk/engines/scumm/intern.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/intern.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -848,7 +848,7 @@
 	byte VAR_TIMEDATE_SECOND;
 };
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 class ScummEngine_v7 : public ScummEngine_v6 {
 	friend class SmushPlayer;
 	friend class Insane;

Modified: scummvm/trunk/engines/scumm/module.mk
===================================================================
--- scummvm/trunk/engines/scumm/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -64,7 +64,7 @@
 	proc3ARM.o
 endif
 
-ifndef DISABLE_SCUMM_7_8
+ifdef ENABLE_SCUMM_7_8
 MODULE_OBJS += \
 	nut_renderer.o \
 	script_v8.o \
@@ -104,7 +104,7 @@
 	gfxARM.o
 endif
 
-ifndef DISABLE_HE
+ifdef ENABLE_HE
 MODULE_OBJS += \
 	he/animation_he.o \
 	he/cup_player_he.o \
@@ -121,7 +121,7 @@
 endif
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_SCUMM), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/scumm/nut_renderer.h
===================================================================
--- scummvm/trunk/engines/scumm/nut_renderer.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/nut_renderer.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -22,7 +22,7 @@
  * $Id$
  */
 
-#if !defined(SCUMM_NUT_RENDERER_H) && !defined(DISABLE_SCUMM_7_8)
+#if !defined(SCUMM_NUT_RENDERER_H) && defined(ENABLE_SCUMM_7_8)
 #define SCUMM_NUT_RENDERER_H
 
 #include "common/file.h"

Modified: scummvm/trunk/engines/scumm/object.cpp
===================================================================
--- scummvm/trunk/engines/scumm/object.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/object.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -491,7 +491,7 @@
 			a = _objs[b].parentstate;
 			b = _objs[b].parent;
 			if (b == 0) {
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 				if (_game.heversion >= 71) {
 					if (((ScummEngine_v71he *)this)->_wiz->polygonHit(_objs[i].obj_nr, x, y))
 						return _objs[i].obj_nr;
@@ -614,7 +614,7 @@
 		    (_game.id == GID_FT && getClass(od.obj_nr, kObjectClassPlayer)))
 			flags |= Gdi::dbDrawMaskOnAll;
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 		if (_game.heversion >= 70 && findResource(MKID_BE('SMAP'), ptr) == NULL)
 			_gdi->drawBMAPObject(ptr, &_virtscr[kMainVirtScreen], obj, od.x_pos, od.y_pos, od.width, od.height);
 		else
@@ -1071,7 +1071,7 @@
 	_blastObjectQueuePos = 0;
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 void ScummEngine_v71he::clearDrawQueues() {
 	ScummEngine_v6::clearDrawQueues();
 
@@ -1304,7 +1304,7 @@
 	}
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 int ScummEngine_v8::getObjectIdFromOBIM(const byte *obim) {
 	// In V8, IMHD has no obj_id, but rather a name string. We map the name
 	// back to an object id using a table derived from the DOBJ resource.

Modified: scummvm/trunk/engines/scumm/palette.cpp
===================================================================
--- scummvm/trunk/engines/scumm/palette.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/palette.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -714,7 +714,7 @@
 	}
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 static int HSL2RGBHelper(int n1, int n2, int hue) {
 	if (hue > 360)
 		hue = hue - 360;

Modified: scummvm/trunk/engines/scumm/resource.cpp
===================================================================
--- scummvm/trunk/engines/scumm/resource.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/resource.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -218,7 +218,7 @@
 	char buf[128];
 
 	if (_game.version == 8) {
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 		char result;
 
 		_imuseDigital->stopAllSounds();
@@ -347,7 +347,7 @@
 }
 
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v7::readIndexBlock(uint32 blocktype, uint32 itemsize) {
 	int num;
 	char *ptr;
@@ -1081,7 +1081,7 @@
 		_shadowPalette = (byte *)calloc(_shadowPaletteSize, 1);
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v8::readMAXS(int blockSize) {
 	debug(9, "ScummEngine_v8 readMAXS: MAXS has blocksize %d", blockSize);
 
@@ -1204,7 +1204,7 @@
 #endif
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v8::readGlobalObjects() {
 	int i;
 	int num = _fileHandle->readUint32LE();

Modified: scummvm/trunk/engines/scumm/room.cpp
===================================================================
--- scummvm/trunk/engines/scumm/room.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/room.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -28,7 +28,7 @@
 #include "scumm/actor.h"
 #include "scumm/boxes.h"
 #include "scumm/intern.h"
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 #include "scumm/he/intern_he.h"
 #endif
 #include "scumm/object.h"
@@ -560,7 +560,7 @@
 		}
 	}
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 	// Polygons in HE 80+ games
 	if (_game.heversion >= 80) {
 		ptr = findResourceData(MKID_BE('POLD'), roomptr);

Modified: scummvm/trunk/engines/scumm/saveload.cpp
===================================================================
--- scummvm/trunk/engines/scumm/saveload.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/saveload.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -235,7 +235,7 @@
 	if (!_imuse || _saveSound || !_saveTemporaryState)
 		_sound->stopAllSounds();
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 	if (_imuseDigital) {
 		_imuseDigital->stopAllSounds();
 		_imuseDigital->resetState();
@@ -1239,7 +1239,7 @@
 	s->saveLoadEntries(this, cursorEntries);
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v7::saveOrLoad(Serializer *s) {
 	ScummEngine::saveOrLoad(s);
 
@@ -1292,7 +1292,7 @@
 	s->saveLoadEntries(this, HE70Entries);
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 void ScummEngine_v71he::saveOrLoad(Serializer *s) {
 	ScummEngine_v70he::saveOrLoad(s);
 

Modified: scummvm/trunk/engines/scumm/script_v6.cpp
===================================================================
--- scummvm/trunk/engines/scumm/script_v6.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/script_v6.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -1102,7 +1102,7 @@
 	if (_game.heversion >= 60 && (_game.id != GID_PUTTDEMO))
 		offset = pop();
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 	if (_game.version >= 7)
 		_imuseDigital->startSfx(pop(), 64);
 	else
@@ -2545,7 +2545,7 @@
 	// So, we just handle this as no-op opcode.
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v7::o6_kernelSetFunctions() {
 	int args[30];
 	int num;

Modified: scummvm/trunk/engines/scumm/scumm.cpp
===================================================================
--- scummvm/trunk/engines/scumm/scumm.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/scumm.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -736,7 +736,7 @@
 	free(_storedFlObjects);
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 ScummEngine_v71he::ScummEngine_v71he(OSystem *syst, const DetectorResult &dr)
 	: ScummEngine_v70he(syst, dr) {
 	_auxBlocksNum = 0;
@@ -858,7 +858,7 @@
 
 #endif
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 ScummEngine_v7::ScummEngine_v7(OSystem *syst, const DetectorResult &dr)
 	: ScummEngine_v6(syst, dr) {
 	_verbLineSpacing = 10;
@@ -927,7 +927,7 @@
 		File::addDefaultDirectory(_gameDataPath + "Rooms 3/");
 	}
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 #ifdef MACOSX
 	if (_game.version == 8 && !memcmp(_gameDataPath.c_str(), "/Volumes/MONKEY3_", 17)) {
 		// Special case for COMI on Mac OS X. The mount points on OS X depend
@@ -1212,7 +1212,7 @@
 	_compositeBuf = (byte *)malloc(_screenWidth * _textSurfaceMultiplier * _screenHeight * _textSurfaceMultiplier);
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v7::setupScumm() {
 
 	_musicEngine = _imuseDigital = new IMuseDigital(this, _mixer, 10);
@@ -1238,7 +1238,7 @@
 		_charset = new CharsetRendererV2(this, _language);
 	else if (_game.version == 3)
 		_charset = new CharsetRendererV3(this);
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 	else if (_game.version == 8)
 		_charset = new CharsetRendererNut(this);
 #endif
@@ -1479,7 +1479,7 @@
 		setCursorHotspot(16, 16);
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 void ScummEngine_v72he::resetScumm() {
 	ScummEngine_v60he::resetScumm();
 
@@ -1954,7 +1954,7 @@
 	CursorMan.showMouse(_cursor.state > 0);
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 void ScummEngine_v90he::scummLoop(int delta) {
 	_moviePlay->handleNextFrame();
 	if (_game.heversion >= 98) {
@@ -2051,7 +2051,7 @@
 	}
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v8::scummLoop_handleSaveLoad() {
 	ScummEngine::scummLoop_handleSaveLoad();
 
@@ -2067,7 +2067,7 @@
 	processDrawQue();
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v7::scummLoop_handleDrawing() {
 	ScummEngine_v6::scummLoop_handleDrawing();
 
@@ -2077,7 +2077,7 @@
 }
 #endif
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 void ScummEngine_v90he::scummLoop_handleDrawing() {
 	ScummEngine_v80he::scummLoop_handleDrawing();
 
@@ -2125,7 +2125,7 @@
 	_sound->processSound();
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v7::scummLoop_handleSound() {
 	ScummEngine_v6::scummLoop_handleSound();
 	if (_imuseDigital) {
@@ -2226,7 +2226,7 @@
 		runScript(1, 0, 0, args);
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 void ScummEngine_v90he::runBootscript() {
 	if (_game.heversion >= 98) {
 		_logicHE->initOnce();
@@ -2284,7 +2284,7 @@
 	return result;
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 int ScummEngine_v7::runDialog(Dialog &dialog) {
 	_splayer->pause();
 	int result = ScummEngine::runDialog(dialog);

Modified: scummvm/trunk/engines/scumm/smush/smush_player.h
===================================================================
--- scummvm/trunk/engines/scumm/smush/smush_player.h	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/smush/smush_player.h	2008-05-06 03:00:26 UTC (rev 31888)
@@ -23,7 +23,7 @@
  *
  */
 
-#if !defined(SCUMM_SMUSH_PLAYER_H) && !defined(DISABLE_SCUMM_7_8)
+#if !defined(SCUMM_SMUSH_PLAYER_H) && defined(ENABLE_SCUMM_7_8)
 #define SCUMM_SMUSH_PLAYER_H
 
 #include "common/util.h"

Modified: scummvm/trunk/engines/scumm/sound.cpp
===================================================================
--- scummvm/trunk/engines/scumm/sound.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/sound.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -675,7 +675,7 @@
 		}
 
 		if (_vm->_imuseDigital) {
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 			//_vm->_imuseDigital->stopSound(kTalkSoundID);
 			_vm->_imuseDigital->startVoice(kTalkSoundID, input);
 #endif
@@ -688,7 +688,7 @@
 void Sound::stopTalkSound() {
 	if (_sfxMode & 2) {
 		if (_vm->_imuseDigital) {
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 			_vm->_imuseDigital->stopSound(kTalkSoundID);
 #endif
 		} else if (_vm->_game.heversion >= 60) {
@@ -718,7 +718,7 @@
 }
 
 int Sound::isSoundRunning(int sound) const {
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 	if (_vm->_imuseDigital)
 		return (_vm->_imuseDigital->getSoundStatus(sound) != 0);
 #endif
@@ -754,7 +754,7 @@
  */
 bool Sound::isSoundInUse(int sound) const {
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 	if (_vm->_imuseDigital)
 		return (_vm->_imuseDigital->getSoundStatus(sound) != 0);
 #endif
@@ -848,7 +848,7 @@
 void Sound::soundKludge(int *list, int num) {
 	int i;
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 	if (_vm->_imuseDigital) {
 		_vm->_imuseDigital->parseScriptCmds(list[0], list[1], list[2], list[3], list[4],
 												list[5], list[6], list[7]);
@@ -912,7 +912,7 @@
 
 	_soundsPaused = pause;
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 	if (_vm->_imuseDigital) {
 		_vm->_imuseDigital->pause(pause);
 	}

Modified: scummvm/trunk/engines/scumm/string.cpp
===================================================================
--- scummvm/trunk/engines/scumm/string.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/string.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -34,7 +34,7 @@
 #include "scumm/file.h"
 #include "scumm/imuse_digi/dimuse.h"
 #include "scumm/intern.h"
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 #include "scumm/he/intern_he.h"
 #endif
 #include "scumm/verbs.h"
@@ -66,7 +66,7 @@
 	}
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v8::printString(int m, const byte *msg) {
 	if (m == 4) {
 		const StringTab &st = _string[m];
@@ -220,7 +220,7 @@
 #pragma mark -
 
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v7::processSubtitleQueue() {
 	for (int i = 0; i < _subtitleQueuePos; ++i) {
 		SubtitleText *st = &_subtitleQueue[i];
@@ -353,7 +353,7 @@
 	return (c != 2 && c != 3);
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 bool ScummEngine_v72he::handleNextCharsetCode(Actor *a, int *code) {
 	const int charsetCode = (_game.heversion >= 80) ? 127 : 64;
 	uint32 talk_sound_a = 0;
@@ -431,7 +431,7 @@
 
 void ScummEngine::CHARSET_1() {
 	Actor *a;
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 	byte subtitleBuffer[200];
 	byte *subtitleLine = subtitleBuffer;
 	Common::Point subtitlePos;
@@ -533,7 +533,7 @@
 
 	if (!_keepText) {
 		if (_game.version >= 7) {
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 			((ScummEngine_v7 *)this)->clearSubtitleQueue();
 			_nextLeft = _string[0].xpos;
 			_nextTop = _string[0].ypos + _screenTop;
@@ -574,7 +574,7 @@
 		if (c == 13) {
 		newLine:;
 			_nextLeft = _string[0].xpos;
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 			if (_game.version >= 7 && subtitleLine != subtitleBuffer) {
 				((ScummEngine_v7 *)this)->addSubtitleToQueue(subtitleBuffer, subtitlePos, _charsetColor, _charset->getCurID());
 				subtitleLine = subtitleBuffer;
@@ -613,7 +613,7 @@
 		_charset->_top = _nextTop;
 
 		if (_game.version >= 7) {
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 			if (subtitleLine == subtitleBuffer) {
 				subtitlePos.x = _charset->_left;
 				// BlastText position is relative to the top of the screen, adjust y-coordinate
@@ -660,14 +660,14 @@
 		}
 	}
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 	if (_game.version >= 7 && subtitleLine != subtitleBuffer) {
 		((ScummEngine_v7 *)this)->addSubtitleToQueue(subtitleBuffer, subtitlePos, _charsetColor, _charset->getCurID());
 	}
 #endif
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v7::CHARSET_1() {
 	if (_game.id == GID_FT) {
 		ScummEngine::CHARSET_1();
@@ -1128,7 +1128,7 @@
 	return dstSize - (end - dst);
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 int ScummEngine_v72he::convertMessageToString(const byte *msg, byte *dst, int dstSize) {
 	uint num = 0;
 	byte chr;
@@ -1245,7 +1245,7 @@
 #pragma mark -
 
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 void ScummEngine_v80he::initCharset(int charsetno) {
 	ScummEngine::initCharset(charsetno);
 	VAR(VAR_CURRENT_CHARSET) = charsetno;
@@ -1273,7 +1273,7 @@
 #pragma mark -
 
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 static int indexCompare(const void *p1, const void *p2) {
 	const ScummEngine_v7::LangIndexNode *i1 = (const ScummEngine_v7::LangIndexNode *) p1;
 	const ScummEngine_v7::LangIndexNode *i2 = (const ScummEngine_v7::LangIndexNode *) p2;

Modified: scummvm/trunk/engines/scumm/vars.cpp
===================================================================
--- scummvm/trunk/engines/scumm/vars.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/vars.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -216,7 +216,7 @@
 	VAR_SOUND_CHANNEL = 14;
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 void ScummEngine_v72he::setupScummVars() {
 	VAR_KEYPRESS = 0;
 	VAR_DEBUGMODE = 1;
@@ -333,7 +333,7 @@
 }
 #endif
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v7::setupScummVars() {
 	VAR_MOUSE_X = 1;
 	VAR_MOUSE_Y = 2;
@@ -568,7 +568,7 @@
 		_scummVars[74] = 1225;
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v7::resetScummVars() {
 	ScummEngine::resetScummVars();
 
@@ -633,7 +633,7 @@
 	VAR(VAR_TALK_CHANNEL) = 2;
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 void ScummEngine_v72he::resetScummVars() {
 	ScummEngine_v70he::resetScummVars();
 

Modified: scummvm/trunk/engines/scumm/verbs.cpp
===================================================================
--- scummvm/trunk/engines/scumm/verbs.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/scumm/verbs.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -514,7 +514,7 @@
 	drawSentence();
 }
 
-#ifndef DISABLE_HE
+#ifdef ENABLE_HE
 void ScummEngine_v72he::checkExecVerbs() {
 	VAR(VAR_MOUSE_STATE) = 0;
 
@@ -797,7 +797,7 @@
 	return 0;
 }
 
-#ifndef DISABLE_SCUMM_7_8
+#ifdef ENABLE_SCUMM_7_8
 void ScummEngine_v7::drawVerb(int verb, int mode) {
 	VerbSlot *vs;
 

Modified: scummvm/trunk/engines/sky/module.mk
===================================================================
--- scummvm/trunk/engines/sky/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/sky/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -24,7 +24,7 @@
 	music/musicbase.o
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_SKY), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/sky/sky.cpp
===================================================================
--- scummvm/trunk/engines/sky/sky.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/sky/sky.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -247,7 +247,11 @@
 	return saveList;
 }
 
-REGISTER_PLUGIN(SKY, PLUGIN_TYPE_ENGINE, SkyMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(SKY)
+	REGISTER_PLUGIN_DYNAMIC(SKY, PLUGIN_TYPE_ENGINE, SkyMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(SKY, PLUGIN_TYPE_ENGINE, SkyMetaEngine);
+#endif
 
 namespace Sky {
 

Modified: scummvm/trunk/engines/sword1/module.mk
===================================================================
--- scummvm/trunk/engines/sword1/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/sword1/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -21,7 +21,7 @@
 	text.o
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_SWORD1), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/sword1/sword1.cpp
===================================================================
--- scummvm/trunk/engines/sword1/sword1.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/sword1/sword1.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -187,7 +187,11 @@
 	return kNoError;
 }
 
-REGISTER_PLUGIN(SWORD1, PLUGIN_TYPE_ENGINE, SwordMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(SWORD1)
+	REGISTER_PLUGIN_DYNAMIC(SWORD1, PLUGIN_TYPE_ENGINE, SwordMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(SWORD1, PLUGIN_TYPE_ENGINE, SwordMetaEngine);
+#endif
 
 namespace Sword1 {
 

Modified: scummvm/trunk/engines/sword2/module.mk
===================================================================
--- scummvm/trunk/engines/sword2/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/sword2/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -34,7 +34,7 @@
 	walker.o
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_SWORD2), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/engines/sword2/sword2.cpp
===================================================================
--- scummvm/trunk/engines/sword2/sword2.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/sword2/sword2.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -180,7 +180,11 @@
 	return kNoGameDataFoundError;
 }
 
-REGISTER_PLUGIN(SWORD2, PLUGIN_TYPE_ENGINE, Sword2MetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(SWORD2)
+	REGISTER_PLUGIN_DYNAMIC(SWORD2, PLUGIN_TYPE_ENGINE, Sword2MetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(SWORD2, PLUGIN_TYPE_ENGINE, Sword2MetaEngine);
+#endif
 
 namespace Sword2 {
 

Modified: scummvm/trunk/engines/touche/detection.cpp
===================================================================
--- scummvm/trunk/engines/touche/detection.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/touche/detection.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -146,4 +146,8 @@
 	return gd != 0;
 }
 
-REGISTER_PLUGIN(TOUCHE, PLUGIN_TYPE_ENGINE, ToucheMetaEngine);
+#if PLUGIN_ENABLED_DYNAMIC(TOUCHE)
+	REGISTER_PLUGIN_DYNAMIC(TOUCHE, PLUGIN_TYPE_ENGINE, ToucheMetaEngine);
+#else
+	REGISTER_PLUGIN_STATIC(TOUCHE, PLUGIN_TYPE_ENGINE, ToucheMetaEngine);
+#endif

Modified: scummvm/trunk/engines/touche/module.mk
===================================================================
--- scummvm/trunk/engines/touche/module.mk	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/engines/touche/module.mk	2008-05-06 03:00:26 UTC (rev 31888)
@@ -12,7 +12,7 @@
 	touche.o
 
 # This module can be built as a plugin
-ifdef BUILD_PLUGINS
+ifeq ($(ENABLE_TOUCHE), DYNAMIC_PLUGIN)
 PLUGIN := 1
 endif
 

Modified: scummvm/trunk/sound/mididrv.cpp
===================================================================
--- scummvm/trunk/sound/mididrv.cpp	2008-05-05 22:52:28 UTC (rev 31887)
+++ scummvm/trunk/sound/mididrv.cpp	2008-05-06 03:00:26 UTC (rev 31888)
@@ -68,7 +68,7 @@
 #if defined(PALMOS_MODE)
 #	if defined(COMPILE_CLIE)
 	{"ypa1", "Yamaha Pa1", MD_YPA1, MDT_MIDI},
-#	elif defined(COMPILE_ZODIAC) && (defined(DISABLE_SCUMM) || !defined(PALMOS_ARM))
+#	elif defined(COMPILE_ZODIAC) && (!defined(ENABLE_SCUMM) || !defined(PALMOS_ARM))
 	{"zodiac", "Tapwave Zodiac", MD_ZODIAC, MDT_MIDI},
 #	endif
 #endif
@@ -239,7 +239,7 @@
 #if defined(PALMOS_MODE)
 #if defined(COMPILE_CLIE)
 	case MD_YPA1:      return MidiDriver_YamahaPa1_create();
-#elif defined(COMPILE_ZODIAC) && (defined(DISABLE_SCUMM) || !defined(PALMOS_ARM))
+#elif defined(COMPILE_ZODIAC) && (!defined(ENABLE_SCUMM) || !defined(PALMOS_ARM))
 	case MD_ZODIAC:    return MidiDriver_Zodiac_create();
 #endif
 #endif


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list