[Scummvm-cvs-logs] scummvm master -> 0e017f007a8a3db8c8d8320f76cbfd423e662e07

lordhoto lordhoto at gmail.com
Tue Nov 26 11:32:57 CET 2013


This automated email contains information about 15 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
aa947c9474 BUILD: Split configure.engines down to a single file per engine.
d77cf95a18 BUILD: Split engines.mk down to a single file per engine.
00c27a28f9 BUILD: Split engines/plugins_table header down to a file per engine.
1ac01d2333 BUILD: Remove need for engine-plugin.h in engines.
ef85456859 BUILD: Remove need for engine.mk in each engine directory.
6e29e1abee DEVTOOLS: Adapt create_project for new configure.engine files.
100e45e748 BUILD: Add engines/plugins_table.h to git in the ideprojects target.
9c02552358 BUILD: Partial solution for parallel make issue.
19a20ad71f BUILD: Create engines/ dir if necessary, to fix out-of-tree builds
c00ab00f25 DEVTOOLS: Factor out function to create directories in create_project.
8b3fc996a1 DEVTOOLS: Adapt create_project to create engines/ dir if necessary
ffce805fb2 BUILD: Add code to maintain ordering of engines in generated files.
80136c1e51 DEVTOOLS: Make create_project sort SCUMM as first engine.
6b0f1118de DEVTOOLS: Add project file directory to include path in generated project files.
0e017f007a Merge pull request #375 from digitall/engineAutoPlug


Commit: aa947c9474ad83aa9315bc585d1f0b79060fee61
    https://github.com/scummvm/scummvm/commit/aa947c9474ad83aa9315bc585d1f0b79060fee61
Author: D G Turner (digitall at scummvm.org)
Date: 2013-11-23T16:45:38-08:00

Commit Message:
BUILD: Split configure.engines down to a single file per engine.

This is the first part of allowing engines to be added dynamically.
They are placed into a folder in engines/ which must contain a file
named "configure.engine" to add the engine, which is pulled into the
top level configure script automatically.

Changed paths:
  A engines/agi/configure.engine
  A engines/agos/configure.engine
  A engines/avalanche/configure.engine
  A engines/cge/configure.engine
  A engines/cine/configure.engine
  A engines/composer/configure.engine
  A engines/cruise/configure.engine
  A engines/draci/configure.engine
  A engines/drascula/configure.engine
  A engines/dreamweb/configure.engine
  A engines/fullpipe/configure.engine
  A engines/gob/configure.engine
  A engines/groovie/configure.engine
  A engines/hopkins/configure.engine
  A engines/hugo/configure.engine
  A engines/kyra/configure.engine
  A engines/lastexpress/configure.engine
  A engines/lure/configure.engine
  A engines/made/configure.engine
  A engines/mohawk/configure.engine
  A engines/mortevielle/configure.engine
  A engines/neverhood/configure.engine
  A engines/parallaction/configure.engine
  A engines/pegasus/configure.engine
  A engines/queen/configure.engine
  A engines/saga/configure.engine
  A engines/sci/configure.engine
  A engines/scumm/configure.engine
  A engines/sky/configure.engine
  A engines/sword1/configure.engine
  A engines/sword2/configure.engine
  A engines/sword25/configure.engine
  A engines/teenagent/configure.engine
  A engines/testbed/configure.engine
  A engines/tinsel/configure.engine
  A engines/toltecs/configure.engine
  A engines/tony/configure.engine
  A engines/toon/configure.engine
  A engines/touche/configure.engine
  A engines/tsage/configure.engine
  A engines/tucker/configure.engine
  A engines/wintermute/configure.engine
  A engines/zvision/configure.engine
  R engines/configure.engines
    Makefile
    configure



diff --git a/Makefile b/Makefile
index 09c38b2..2ff67ee 100644
--- a/Makefile
+++ b/Makefile
@@ -82,7 +82,8 @@ EXECUTABLE  := $(EXEPRE)scummvm$(EXEEXT)
 include $(srcdir)/Makefile.common
 
 # check if configure has been run or has been changed since last run
-config.h config.mk: $(srcdir)/configure $(srcdir)/engines/configure.engines
+ENGINE_SUBDIRS_CONFIGURE := $(wildcard $(srcdir)/engines/*/configure.engine)
+config.h config.mk: $(srcdir)/configure $(ENGINE_SUBDIRS_CONFIGURE)
 ifeq "$(findstring config.mk,$(MAKEFILE_LIST))" "config.mk"
 	@echo "Running $(srcdir)/configure with the last specified parameters"
 	@sleep 2
diff --git a/configure b/configure
index cb0b890..4825cdc 100755
--- a/configure
+++ b/configure
@@ -97,7 +97,9 @@ add_feature() {
 _srcdir=`dirname $0`
 
 # Read list of engines
-. $_srcdir/engines/configure.engines
+for i in $_srcdir/engines/*/configure.engine; do
+	. "$i"
+done
 
 #
 # Default settings
diff --git a/engines/agi/configure.engine b/engines/agi/configure.engine
new file mode 100644
index 0000000..fad659f
--- /dev/null
+++ b/engines/agi/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine agi "AGI" yes
diff --git a/engines/agos/configure.engine b/engines/agos/configure.engine
new file mode 100644
index 0000000..3ae1fb1
--- /dev/null
+++ b/engines/agos/configure.engine
@@ -0,0 +1,4 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine agos "AGOS" yes "agos2" "AGOS 1 games"
+add_engine agos2 "AGOS 2 games" yes
diff --git a/engines/avalanche/configure.engine b/engines/avalanche/configure.engine
new file mode 100644
index 0000000..28d6a55
--- /dev/null
+++ b/engines/avalanche/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine avalanche "Lord Avalot d'Argent" no
diff --git a/engines/cge/configure.engine b/engines/cge/configure.engine
new file mode 100644
index 0000000..72af119
--- /dev/null
+++ b/engines/cge/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine cge "CGE" yes
diff --git a/engines/cine/configure.engine b/engines/cine/configure.engine
new file mode 100644
index 0000000..2b7e208
--- /dev/null
+++ b/engines/cine/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine cine "Cinematique evo 1" yes
diff --git a/engines/composer/configure.engine b/engines/composer/configure.engine
new file mode 100644
index 0000000..71a79ac
--- /dev/null
+++ b/engines/composer/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine composer "Magic Composer" yes
diff --git a/engines/configure.engines b/engines/configure.engines
deleted file mode 100644
index ec7d466..0000000
--- a/engines/configure.engines
+++ /dev/null
@@ -1,57 +0,0 @@
-# This file is included from the main "configure" script
-# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
-add_engine scumm "SCUMM" yes "scumm_7_8 he" "v0-v6 games"
-add_engine scumm_7_8 "v7 & v8 games" yes
-add_engine he "HE71+ games" yes
-add_engine agi "AGI" yes
-add_engine agos "AGOS" yes "agos2" "AGOS 1 games"
-add_engine agos2 "AGOS 2 games" yes
-add_engine avalanche "Lord Avalot d'Argent" no
-add_engine cge "CGE" yes
-add_engine cine "Cinematique evo 1" yes
-add_engine composer "Magic Composer" yes
-add_engine cruise "Cinematique evo 2" yes
-add_engine draci "Dragon History" yes
-add_engine drascula "Drascula: The Vampire Strikes Back" yes
-add_engine dreamweb "Dreamweb" yes
-add_engine fullpipe "Full Pipe" no
-add_engine gob "Gobli*ns" yes
-add_engine groovie "Groovie" yes "groovie2" "7th Guest"
-add_engine groovie2 "Groovie 2 games" no "" "" "jpeg"
-add_engine hopkins "Hopkins FBI" yes "" "" "16bit"
-add_engine hugo "Hugo Trilogy" yes
-add_engine kyra "Kyra" yes "lol eob" "Legend of Kyrandia 1-3"
-add_engine lol "Lands of Lore" yes
-add_engine eob "Eye of the Beholder" yes
-add_engine lastexpress "The Last Express" no "" "" "16bit"
-add_engine lure "Lure of the Temptress" yes
-add_engine made "MADE" yes
-add_engine mohawk "Mohawk" yes "cstime myst riven" "Living Books"
-add_engine mortevielle "Mortevielle" no
-add_engine cstime "Where in Time is Carmen Sandiego?" no
-add_engine riven "Riven: The Sequel to Myst" no "" "" "16bit"
-add_engine myst "Myst" no "" "" "16bit"
-add_engine neverhood "Neverhood" no
-add_engine parallaction "Parallaction" yes
-add_engine pegasus "The Journeyman Project: Pegasus Prime" yes "" "" "16bit"
-add_engine queen "Flight of the Amazon Queen" yes
-add_engine saga "SAGA" yes "ihnm saga2" "ITE"
-add_engine ihnm "IHNM" yes
-add_engine saga2 "SAGA 2 games" no
-add_engine sci "SCI" yes "sci32" "SCI 0-1.1 games"
-add_engine sci32 "SCI32 games" no
-add_engine sky "Beneath a Steel Sky" yes
-add_engine sword1 "Broken Sword" yes
-add_engine sword2 "Broken Sword II" yes
-add_engine sword25 "Broken Sword 2.5" no "" "" "png zlib 16bit"
-add_engine teenagent "Teen Agent" yes
-add_engine testbed "TestBed: the Testing framework" no
-add_engine tinsel "Tinsel" yes
-add_engine toltecs "3 Skulls of the Toltecs" yes
-add_engine toon "Toonstruck" yes
-add_engine touche "Touche: The Adventures of the Fifth Musketeer" yes
-add_engine tony "Tony Tough and the Night of Roasted Moths" yes "" "" "16bit"
-add_engine tsage "TsAGE" yes
-add_engine tucker "Bud Tucker in Double Trouble" yes
-add_engine wintermute "Wintermute" no "" "" "jpeg png zlib vorbis 16bit"
-add_engine zvision "ZVision" no "" "" "freetype2 16bit"
diff --git a/engines/cruise/configure.engine b/engines/cruise/configure.engine
new file mode 100644
index 0000000..925da25
--- /dev/null
+++ b/engines/cruise/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine cruise "Cinematique evo 2" yes
diff --git a/engines/draci/configure.engine b/engines/draci/configure.engine
new file mode 100644
index 0000000..09022b0
--- /dev/null
+++ b/engines/draci/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine draci "Dragon History" yes
diff --git a/engines/drascula/configure.engine b/engines/drascula/configure.engine
new file mode 100644
index 0000000..b9b7663
--- /dev/null
+++ b/engines/drascula/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine drascula "Drascula: The Vampire Strikes Back" yes
diff --git a/engines/dreamweb/configure.engine b/engines/dreamweb/configure.engine
new file mode 100644
index 0000000..27506e6
--- /dev/null
+++ b/engines/dreamweb/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine dreamweb "Dreamweb" yes
diff --git a/engines/fullpipe/configure.engine b/engines/fullpipe/configure.engine
new file mode 100644
index 0000000..fce5951
--- /dev/null
+++ b/engines/fullpipe/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine fullpipe "Full Pipe" no
diff --git a/engines/gob/configure.engine b/engines/gob/configure.engine
new file mode 100644
index 0000000..8e012f5
--- /dev/null
+++ b/engines/gob/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine gob "Gobli*ns" yes
diff --git a/engines/groovie/configure.engine b/engines/groovie/configure.engine
new file mode 100644
index 0000000..84e95a7
--- /dev/null
+++ b/engines/groovie/configure.engine
@@ -0,0 +1,4 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine groovie "Groovie" yes "groovie2" "7th Guest"
+add_engine groovie2 "Groovie 2 games" no "" "" "jpeg"
diff --git a/engines/hopkins/configure.engine b/engines/hopkins/configure.engine
new file mode 100644
index 0000000..c38ecd4
--- /dev/null
+++ b/engines/hopkins/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine hopkins "Hopkins FBI" yes "" "" "16bit"
diff --git a/engines/hugo/configure.engine b/engines/hugo/configure.engine
new file mode 100644
index 0000000..9ab5c54
--- /dev/null
+++ b/engines/hugo/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine hugo "Hugo Trilogy" yes
diff --git a/engines/kyra/configure.engine b/engines/kyra/configure.engine
new file mode 100644
index 0000000..b7d6334
--- /dev/null
+++ b/engines/kyra/configure.engine
@@ -0,0 +1,5 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine kyra "Kyra" yes "lol eob" "Legend of Kyrandia 1-3"
+add_engine lol "Lands of Lore" yes
+add_engine eob "Eye of the Beholder" yes
diff --git a/engines/lastexpress/configure.engine b/engines/lastexpress/configure.engine
new file mode 100644
index 0000000..807b1a0
--- /dev/null
+++ b/engines/lastexpress/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine lastexpress "The Last Express" no "" "" "16bit"
diff --git a/engines/lure/configure.engine b/engines/lure/configure.engine
new file mode 100644
index 0000000..e9f9289
--- /dev/null
+++ b/engines/lure/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine lure "Lure of the Temptress" yes
diff --git a/engines/made/configure.engine b/engines/made/configure.engine
new file mode 100644
index 0000000..2266712
--- /dev/null
+++ b/engines/made/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine made "MADE" yes
diff --git a/engines/mohawk/configure.engine b/engines/mohawk/configure.engine
new file mode 100644
index 0000000..fa9d15c
--- /dev/null
+++ b/engines/mohawk/configure.engine
@@ -0,0 +1,6 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine mohawk "Mohawk" yes "cstime myst riven" "Living Books"
+add_engine cstime "Where in Time is Carmen Sandiego?" no
+add_engine riven "Riven: The Sequel to Myst" no "" "" "16bit"
+add_engine myst "Myst" no "" "" "16bit"
diff --git a/engines/mortevielle/configure.engine b/engines/mortevielle/configure.engine
new file mode 100644
index 0000000..14d6479
--- /dev/null
+++ b/engines/mortevielle/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine mortevielle "Mortevielle" no
diff --git a/engines/neverhood/configure.engine b/engines/neverhood/configure.engine
new file mode 100644
index 0000000..0767a63
--- /dev/null
+++ b/engines/neverhood/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine neverhood "Neverhood" no
diff --git a/engines/parallaction/configure.engine b/engines/parallaction/configure.engine
new file mode 100644
index 0000000..babca45
--- /dev/null
+++ b/engines/parallaction/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine parallaction "Parallaction" yes
diff --git a/engines/pegasus/configure.engine b/engines/pegasus/configure.engine
new file mode 100644
index 0000000..ed7e295
--- /dev/null
+++ b/engines/pegasus/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine pegasus "The Journeyman Project: Pegasus Prime" yes "" "" "16bit"
diff --git a/engines/queen/configure.engine b/engines/queen/configure.engine
new file mode 100644
index 0000000..c876674
--- /dev/null
+++ b/engines/queen/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine queen "Flight of the Amazon Queen" yes
diff --git a/engines/saga/configure.engine b/engines/saga/configure.engine
new file mode 100644
index 0000000..99e2ab3
--- /dev/null
+++ b/engines/saga/configure.engine
@@ -0,0 +1,5 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine saga "SAGA" yes "ihnm saga2" "ITE"
+add_engine ihnm "IHNM" yes
+add_engine saga2 "SAGA 2 games" no
diff --git a/engines/sci/configure.engine b/engines/sci/configure.engine
new file mode 100644
index 0000000..d1c45a4
--- /dev/null
+++ b/engines/sci/configure.engine
@@ -0,0 +1,4 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine sci "SCI" yes "sci32" "SCI 0-1.1 games"
+add_engine sci32 "SCI32 games" no
diff --git a/engines/scumm/configure.engine b/engines/scumm/configure.engine
new file mode 100644
index 0000000..e1de788
--- /dev/null
+++ b/engines/scumm/configure.engine
@@ -0,0 +1,5 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine scumm "SCUMM" yes "scumm_7_8 he" "v0-v6 games"
+add_engine scumm_7_8 "v7 & v8 games" yes
+add_engine he "HE71+ games" yes
diff --git a/engines/sky/configure.engine b/engines/sky/configure.engine
new file mode 100644
index 0000000..32b8484
--- /dev/null
+++ b/engines/sky/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine sky "Beneath a Steel Sky" yes
diff --git a/engines/sword1/configure.engine b/engines/sword1/configure.engine
new file mode 100644
index 0000000..0578d17
--- /dev/null
+++ b/engines/sword1/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine sword1 "Broken Sword" yes
diff --git a/engines/sword2/configure.engine b/engines/sword2/configure.engine
new file mode 100644
index 0000000..7153605
--- /dev/null
+++ b/engines/sword2/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine sword2 "Broken Sword II" yes
diff --git a/engines/sword25/configure.engine b/engines/sword25/configure.engine
new file mode 100644
index 0000000..1729bbe
--- /dev/null
+++ b/engines/sword25/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine sword25 "Broken Sword 2.5" no "" "" "png zlib 16bit"
diff --git a/engines/teenagent/configure.engine b/engines/teenagent/configure.engine
new file mode 100644
index 0000000..223a0e8
--- /dev/null
+++ b/engines/teenagent/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine teenagent "Teen Agent" yes
diff --git a/engines/testbed/configure.engine b/engines/testbed/configure.engine
new file mode 100644
index 0000000..c0a68c8
--- /dev/null
+++ b/engines/testbed/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine testbed "TestBed: the Testing framework" no
diff --git a/engines/tinsel/configure.engine b/engines/tinsel/configure.engine
new file mode 100644
index 0000000..c0f3e0a
--- /dev/null
+++ b/engines/tinsel/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine tinsel "Tinsel" yes
diff --git a/engines/toltecs/configure.engine b/engines/toltecs/configure.engine
new file mode 100644
index 0000000..be5533e
--- /dev/null
+++ b/engines/toltecs/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine toltecs "3 Skulls of the Toltecs" yes
diff --git a/engines/tony/configure.engine b/engines/tony/configure.engine
new file mode 100644
index 0000000..f85f45d
--- /dev/null
+++ b/engines/tony/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine tony "Tony Tough and the Night of Roasted Moths" yes "" "" "16bit"
diff --git a/engines/toon/configure.engine b/engines/toon/configure.engine
new file mode 100644
index 0000000..00c98f7
--- /dev/null
+++ b/engines/toon/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine toon "Toonstruck" yes
diff --git a/engines/touche/configure.engine b/engines/touche/configure.engine
new file mode 100644
index 0000000..777578e
--- /dev/null
+++ b/engines/touche/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine touche "Touche: The Adventures of the Fifth Musketeer" yes
diff --git a/engines/tsage/configure.engine b/engines/tsage/configure.engine
new file mode 100644
index 0000000..2b8edf8
--- /dev/null
+++ b/engines/tsage/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine tsage "TsAGE" yes
diff --git a/engines/tucker/configure.engine b/engines/tucker/configure.engine
new file mode 100644
index 0000000..06676cf
--- /dev/null
+++ b/engines/tucker/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine tucker "Bud Tucker in Double Trouble" yes
diff --git a/engines/wintermute/configure.engine b/engines/wintermute/configure.engine
new file mode 100644
index 0000000..673549b
--- /dev/null
+++ b/engines/wintermute/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine wintermute "Wintermute" no "" "" "jpeg png zlib vorbis 16bit"
diff --git a/engines/zvision/configure.engine b/engines/zvision/configure.engine
new file mode 100644
index 0000000..02e3194
--- /dev/null
+++ b/engines/zvision/configure.engine
@@ -0,0 +1,3 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine zvision "ZVision" no "" "" "freetype2 16bit"


Commit: d77cf95a185a6c8f201f417d08f246727784f728
    https://github.com/scummvm/scummvm/commit/d77cf95a185a6c8f201f417d08f246727784f728
Author: D G Turner (digitall at scummvm.org)
Date: 2013-11-23T16:48:01-08:00

Commit Message:
BUILD: Split engines.mk down to a single file per engine.

This is the second part of allowing engines to be added dynamically.
Each folder in engines/ which must contain a file named "engine.mk"
containing the make definitions for that engine.

Changed paths:
  A engines/agi/engine.mk
  A engines/agos/engine.mk
  A engines/avalanche/engine.mk
  A engines/cge/engine.mk
  A engines/cine/engine.mk
  A engines/composer/engine.mk
  A engines/cruise/engine.mk
  A engines/draci/engine.mk
  A engines/drascula/engine.mk
  A engines/dreamweb/engine.mk
  A engines/fullpipe/engine.mk
  A engines/gob/engine.mk
  A engines/groovie/engine.mk
  A engines/hopkins/engine.mk
  A engines/hugo/engine.mk
  A engines/kyra/engine.mk
  A engines/lastexpress/engine.mk
  A engines/lure/engine.mk
  A engines/made/engine.mk
  A engines/mohawk/engine.mk
  A engines/mortevielle/engine.mk
  A engines/neverhood/engine.mk
  A engines/parallaction/engine.mk
  A engines/pegasus/engine.mk
  A engines/queen/engine.mk
  A engines/saga/engine.mk
  A engines/sci/engine.mk
  A engines/scumm/engine.mk
  A engines/sky/engine.mk
  A engines/sword1/engine.mk
  A engines/sword2/engine.mk
  A engines/sword25/engine.mk
  A engines/teenagent/engine.mk
  A engines/testbed/engine.mk
  A engines/tinsel/engine.mk
  A engines/toltecs/engine.mk
  A engines/tony/engine.mk
  A engines/toon/engine.mk
  A engines/touche/engine.mk
  A engines/tsage/engine.mk
  A engines/tucker/engine.mk
  A engines/wintermute/engine.mk
  A engines/zvision/engine.mk
  R engines/engines.mk
    Makefile.common



diff --git a/Makefile.common b/Makefile.common
index 02c3408..41a3245 100644
--- a/Makefile.common
+++ b/Makefile.common
@@ -16,7 +16,9 @@ all: $(EXECUTABLE) plugins
 PLUGINS :=
 MODULES := test devtools base $(MODULES)
 
--include $(srcdir)/engines/engines.mk
+ENGINE_SUBDIRS_MK := $(wildcard $(srcdir)/engines/*/engine.mk)
+# Include the build instructions for all engines
+-include $(ENGINE_SUBDIRS_MK)
 
 # After the game specific modules follow the shared modules
 MODULES += \
@@ -147,7 +149,7 @@ endif
 # recreate them (which it can't), and in particular from looking for potential
 # source files. This can save quite a bit of disk access time.
 .PHONY: $(wildcard $(addsuffix /*.d,$(DEPDIRS))) $(addprefix $(srcdir)/, $(addsuffix /module.mk,$(MODULES))) \
-	$(srcdir)/$(port_mk) $(srcdir)/rules.mk $(srcdir)/engines/engines.mk
+	$(srcdir)/$(port_mk) $(srcdir)/rules.mk $ENGINE_SUBDIRS_MK
 
 ######################################################################
 # Get the current version information
diff --git a/engines/agi/engine.mk b/engines/agi/engine.mk
new file mode 100644
index 0000000..18963fd
--- /dev/null
+++ b/engines/agi/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_AGI
+DEFINES += -DENABLE_AGI=$(ENABLE_AGI)
+MODULES += engines/agi
+endif
diff --git a/engines/agos/engine.mk b/engines/agos/engine.mk
new file mode 100644
index 0000000..ba60a78
--- /dev/null
+++ b/engines/agos/engine.mk
@@ -0,0 +1,8 @@
+ifdef ENABLE_AGOS
+DEFINES += -DENABLE_AGOS=$(ENABLE_AGOS)
+MODULES += engines/agos
+
+ifdef ENABLE_AGOS2
+DEFINES += -DENABLE_AGOS2
+endif
+endif
diff --git a/engines/avalanche/engine.mk b/engines/avalanche/engine.mk
new file mode 100644
index 0000000..17356ee
--- /dev/null
+++ b/engines/avalanche/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_AVALANCHE
+DEFINES += -DENABLE_AVALANCHE=$(ENABLE_AVALANCHE)
+MODULES += engines/avalanche
+endif
diff --git a/engines/cge/engine.mk b/engines/cge/engine.mk
new file mode 100644
index 0000000..c71f4e0
--- /dev/null
+++ b/engines/cge/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_CGE
+DEFINES += -DENABLE_CGE=$(ENABLE_CGE)
+MODULES += engines/cge
+endif
diff --git a/engines/cine/engine.mk b/engines/cine/engine.mk
new file mode 100644
index 0000000..a32c319
--- /dev/null
+++ b/engines/cine/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_CINE
+DEFINES += -DENABLE_CINE=$(ENABLE_CINE)
+MODULES += engines/cine
+endif
diff --git a/engines/composer/engine.mk b/engines/composer/engine.mk
new file mode 100644
index 0000000..b444021
--- /dev/null
+++ b/engines/composer/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_COMPOSER
+DEFINES += -DENABLE_COMPOSER=$(ENABLE_COMPOSER)
+MODULES += engines/composer
+endif
diff --git a/engines/cruise/engine.mk b/engines/cruise/engine.mk
new file mode 100644
index 0000000..ac37c61
--- /dev/null
+++ b/engines/cruise/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_CRUISE
+DEFINES += -DENABLE_CRUISE=$(ENABLE_CRUISE)
+MODULES += engines/cruise
+endif
diff --git a/engines/draci/engine.mk b/engines/draci/engine.mk
new file mode 100644
index 0000000..81ccc3f
--- /dev/null
+++ b/engines/draci/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_DRACI
+DEFINES += -DENABLE_DRACI=$(ENABLE_DRACI)
+MODULES += engines/draci
+endif
diff --git a/engines/drascula/engine.mk b/engines/drascula/engine.mk
new file mode 100644
index 0000000..ca4f6c9
--- /dev/null
+++ b/engines/drascula/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_DRASCULA
+DEFINES += -DENABLE_DRASCULA=$(ENABLE_DRASCULA)
+MODULES += engines/drascula
+endif
diff --git a/engines/dreamweb/engine.mk b/engines/dreamweb/engine.mk
new file mode 100644
index 0000000..088fcca
--- /dev/null
+++ b/engines/dreamweb/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_DREAMWEB
+DEFINES += -DENABLE_DREAMWEB=$(ENABLE_DREAMWEB)
+MODULES += engines/dreamweb
+endif
diff --git a/engines/engines.mk b/engines/engines.mk
deleted file mode 100644
index cfde773..0000000
--- a/engines/engines.mk
+++ /dev/null
@@ -1,263 +0,0 @@
-ifdef ENABLE_SCUMM
-DEFINES += -DENABLE_SCUMM=$(ENABLE_SCUMM)
-MODULES += engines/scumm
-
-ifdef ENABLE_SCUMM_7_8
-DEFINES += -DENABLE_SCUMM_7_8
-endif
-
-ifdef ENABLE_HE
-DEFINES += -DENABLE_HE
-endif
-
-endif
-
-ifdef ENABLE_AGI
-DEFINES += -DENABLE_AGI=$(ENABLE_AGI)
-MODULES += engines/agi
-endif
-
-ifdef ENABLE_AGOS
-DEFINES += -DENABLE_AGOS=$(ENABLE_AGOS)
-MODULES += engines/agos
-
-ifdef ENABLE_AGOS2
-DEFINES += -DENABLE_AGOS2
-endif
-endif
-
-ifdef ENABLE_AVALANCHE
-DEFINES += -DENABLE_AVALANCHE=$(ENABLE_AVALANCHE)
-MODULES += engines/avalanche
-endif
-
-ifdef ENABLE_CGE
-DEFINES += -DENABLE_CGE=$(ENABLE_CGE)
-MODULES += engines/cge
-endif
-
-ifdef ENABLE_CINE
-DEFINES += -DENABLE_CINE=$(ENABLE_CINE)
-MODULES += engines/cine
-endif
-
-ifdef ENABLE_COMPOSER
-DEFINES += -DENABLE_COMPOSER=$(ENABLE_COMPOSER)
-MODULES += engines/composer
-endif
-
-ifdef ENABLE_CRUISE
-DEFINES += -DENABLE_CRUISE=$(ENABLE_CRUISE)
-MODULES += engines/cruise
-endif
-
-ifdef ENABLE_DRACI
-DEFINES += -DENABLE_DRACI=$(ENABLE_DRACI)
-MODULES += engines/draci
-endif
-
-ifdef ENABLE_DRASCULA
-DEFINES += -DENABLE_DRASCULA=$(ENABLE_DRASCULA)
-MODULES += engines/drascula
-endif
-
-ifdef ENABLE_DREAMWEB
-DEFINES += -DENABLE_DREAMWEB=$(ENABLE_DREAMWEB)
-MODULES += engines/dreamweb
-endif
-
-ifdef ENABLE_FULLPIPE
-DEFINES += -DENABLE_FULLPIPE=$(ENABLE_FULLPIPE)
-MODULES += engines/fullpipe
-endif
-
-ifdef ENABLE_GOB
-DEFINES += -DENABLE_GOB=$(ENABLE_GOB)
-MODULES += engines/gob
-endif
-
-ifdef ENABLE_GROOVIE
-DEFINES += -DENABLE_GROOVIE=$(ENABLE_GROOVIE)
-MODULES += engines/groovie
-
-ifdef ENABLE_GROOVIE2
-DEFINES += -DENABLE_GROOVIE2
-endif
-endif
-
-ifdef ENABLE_HOPKINS
-DEFINES += -DENABLE_HOPKINS=$(ENABLE_HOPKINS)
-MODULES += engines/hopkins
-endif
-
-ifdef ENABLE_HUGO
-DEFINES += -DENABLE_HUGO=$(ENABLE_HUGO)
-MODULES += engines/hugo
-endif
-
-ifdef ENABLE_KYRA
-DEFINES += -DENABLE_KYRA=$(ENABLE_KYRA)
-MODULES += engines/kyra
-
-ifdef ENABLE_LOL
-DEFINES += -DENABLE_LOL
-endif
-
-ifdef ENABLE_EOB
-DEFINES += -DENABLE_EOB
-endif
-endif
-
-ifdef ENABLE_LASTEXPRESS
-DEFINES += -DENABLE_LASTEXPRESS=$(ENABLE_LASTEXPRESS)
-MODULES += engines/lastexpress
-endif
-
-ifdef ENABLE_LURE
-DEFINES += -DENABLE_LURE=$(ENABLE_LURE)
-MODULES += engines/lure
-endif
-
-ifdef ENABLE_MADE
-DEFINES += -DENABLE_MADE=$(ENABLE_MADE)
-MODULES += engines/made
-endif
-
-ifdef ENABLE_MOHAWK
-DEFINES += -DENABLE_MOHAWK=$(ENABLE_MOHAWK)
-MODULES += engines/mohawk
-
-ifdef ENABLE_CSTIME
-DEFINES += -DENABLE_CSTIME
-endif
-
-ifdef ENABLE_MYST
-DEFINES += -DENABLE_MYST
-endif
-
-ifdef ENABLE_RIVEN
-DEFINES += -DENABLE_RIVEN
-endif
-endif
-
-ifdef ENABLE_MORTEVIELLE
-DEFINES += -DENABLE_MORTEVIELLE=$(ENABLE_MORTEVIELLE)
-MODULES += engines/mortevielle
-endif
-
-ifdef ENABLE_NEVERHOOD
-DEFINES += -DENABLE_NEVERHOOD=$(ENABLE_NEVERHOOD)
-MODULES += engines/neverhood
-endif
-
-ifdef ENABLE_PARALLACTION
-DEFINES += -DENABLE_PARALLACTION=$(ENABLE_PARALLACTION)
-MODULES += engines/parallaction
-endif
-
-ifdef ENABLE_PEGASUS
-DEFINES += -DENABLE_PEGASUS=$(ENABLE_PEGASUS)
-MODULES += engines/pegasus
-endif
-
-ifdef ENABLE_QUEEN
-DEFINES += -DENABLE_QUEEN=$(ENABLE_QUEEN)
-MODULES += engines/queen
-endif
-
-ifdef ENABLE_SAGA
-DEFINES += -DENABLE_SAGA=$(ENABLE_SAGA)
-MODULES += engines/saga
-
-ifdef ENABLE_IHNM
-DEFINES += -DENABLE_IHNM
-endif
-
-ifdef ENABLE_SAGA2
-DEFINES += -DENABLE_SAGA2
-endif
-endif
-
-ifdef ENABLE_SCI
-DEFINES += -DENABLE_SCI=$(ENABLE_SCI)
-MODULES += engines/sci
-
-ifdef ENABLE_SCI32
-DEFINES += -DENABLE_SCI32
-endif
-endif
-
-ifdef ENABLE_SKY
-DEFINES += -DENABLE_SKY=$(ENABLE_SKY)
-MODULES += engines/sky
-endif
-
-ifdef ENABLE_SWORD1
-DEFINES += -DENABLE_SWORD1=$(ENABLE_SWORD1)
-MODULES += engines/sword1
-endif
-
-ifdef ENABLE_SWORD2
-DEFINES += -DENABLE_SWORD2=$(ENABLE_SWORD2)
-MODULES += engines/sword2
-endif
-
-ifdef ENABLE_SWORD25
-DEFINES += -DENABLE_SWORD25=$(ENABLE_SWORD25)
-MODULES += engines/sword25
-endif
-
-ifdef ENABLE_TESTBED
-DEFINES += -DENABLE_TESTBED=$(ENABLE_TESTBED)
-MODULES += engines/testbed
-endif
-
-ifdef ENABLE_TEENAGENT
-DEFINES += -DENABLE_TEENAGENT=$(ENABLE_TEENAGENT)
-MODULES += engines/teenagent
-endif
-
-ifdef ENABLE_TINSEL
-DEFINES += -DENABLE_TINSEL=$(ENABLE_TINSEL)
-MODULES += engines/tinsel
-endif
-
-ifdef ENABLE_TOLTECS
-DEFINES += -DENABLE_TOLTECS=$(ENABLE_TOLTECS)
-MODULES += engines/toltecs
-endif
-
-ifdef ENABLE_TONY
-DEFINES += -DENABLE_TONY=$(ENABLE_TONY)
-MODULES += engines/tony
-endif
-
-ifdef ENABLE_TOON
-DEFINES += -DENABLE_TOON=$(ENABLE_TOON)
-MODULES += engines/toon
-endif
-
-ifdef ENABLE_TOUCHE
-DEFINES += -DENABLE_TOUCHE=$(ENABLE_TOUCHE)
-MODULES += engines/touche
-endif
-
-ifdef ENABLE_TSAGE
-DEFINES += -DENABLE_TSAGE=$(ENABLE_TSAGE)
-MODULES += engines/tsage
-endif
-
-ifdef ENABLE_TUCKER
-DEFINES += -DENABLE_TUCKER=$(ENABLE_TUCKER)
-MODULES += engines/tucker
-endif
-
-ifdef ENABLE_WINTERMUTE
-DEFINES += -DENABLE_WINTERMUTE=$(ENABLE_WINTERMUTE)
-MODULES += engines/wintermute
-endif
-
-ifdef ENABLE_ZVISION
-DEFINES += -DENABLE_ZVISION=$(ENABLE_ZVISION)
-MODULES += engines/zvision
-endif
diff --git a/engines/fullpipe/engine.mk b/engines/fullpipe/engine.mk
new file mode 100644
index 0000000..7aeec54
--- /dev/null
+++ b/engines/fullpipe/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_FULLPIPE
+DEFINES += -DENABLE_FULLPIPE=$(ENABLE_FULLPIPE)
+MODULES += engines/fullpipe
+endif
diff --git a/engines/gob/engine.mk b/engines/gob/engine.mk
new file mode 100644
index 0000000..c78e7dd
--- /dev/null
+++ b/engines/gob/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_GOB
+DEFINES += -DENABLE_GOB=$(ENABLE_GOB)
+MODULES += engines/gob
+endif
diff --git a/engines/groovie/engine.mk b/engines/groovie/engine.mk
new file mode 100644
index 0000000..a209860
--- /dev/null
+++ b/engines/groovie/engine.mk
@@ -0,0 +1,8 @@
+ifdef ENABLE_GROOVIE
+DEFINES += -DENABLE_GROOVIE=$(ENABLE_GROOVIE)
+MODULES += engines/groovie
+
+ifdef ENABLE_GROOVIE2
+DEFINES += -DENABLE_GROOVIE2
+endif
+endif
diff --git a/engines/hopkins/engine.mk b/engines/hopkins/engine.mk
new file mode 100644
index 0000000..ac2281c
--- /dev/null
+++ b/engines/hopkins/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_HOPKINS
+DEFINES += -DENABLE_HOPKINS=$(ENABLE_HOPKINS)
+MODULES += engines/hopkins
+endif
diff --git a/engines/hugo/engine.mk b/engines/hugo/engine.mk
new file mode 100644
index 0000000..a6ca531
--- /dev/null
+++ b/engines/hugo/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_HUGO
+DEFINES += -DENABLE_HUGO=$(ENABLE_HUGO)
+MODULES += engines/hugo
+endif
diff --git a/engines/kyra/engine.mk b/engines/kyra/engine.mk
new file mode 100644
index 0000000..a2bfce3
--- /dev/null
+++ b/engines/kyra/engine.mk
@@ -0,0 +1,12 @@
+ifdef ENABLE_KYRA
+DEFINES += -DENABLE_KYRA=$(ENABLE_KYRA)
+MODULES += engines/kyra
+
+ifdef ENABLE_LOL
+DEFINES += -DENABLE_LOL
+endif
+
+ifdef ENABLE_EOB
+DEFINES += -DENABLE_EOB
+endif
+endif
diff --git a/engines/lastexpress/engine.mk b/engines/lastexpress/engine.mk
new file mode 100644
index 0000000..6e0ba3b
--- /dev/null
+++ b/engines/lastexpress/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_LASTEXPRESS
+DEFINES += -DENABLE_LASTEXPRESS=$(ENABLE_LASTEXPRESS)
+MODULES += engines/lastexpress
+endif
diff --git a/engines/lure/engine.mk b/engines/lure/engine.mk
new file mode 100644
index 0000000..62be295
--- /dev/null
+++ b/engines/lure/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_LURE
+DEFINES += -DENABLE_LURE=$(ENABLE_LURE)
+MODULES += engines/lure
+endif
diff --git a/engines/made/engine.mk b/engines/made/engine.mk
new file mode 100644
index 0000000..8fd832c
--- /dev/null
+++ b/engines/made/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_MADE
+DEFINES += -DENABLE_MADE=$(ENABLE_MADE)
+MODULES += engines/made
+endif
diff --git a/engines/mohawk/engine.mk b/engines/mohawk/engine.mk
new file mode 100644
index 0000000..e9474b5
--- /dev/null
+++ b/engines/mohawk/engine.mk
@@ -0,0 +1,16 @@
+ifdef ENABLE_MOHAWK
+DEFINES += -DENABLE_MOHAWK=$(ENABLE_MOHAWK)
+MODULES += engines/mohawk
+
+ifdef ENABLE_CSTIME
+DEFINES += -DENABLE_CSTIME
+endif
+
+ifdef ENABLE_MYST
+DEFINES += -DENABLE_MYST
+endif
+
+ifdef ENABLE_RIVEN
+DEFINES += -DENABLE_RIVEN
+endif
+endif
diff --git a/engines/mortevielle/engine.mk b/engines/mortevielle/engine.mk
new file mode 100644
index 0000000..4232dec
--- /dev/null
+++ b/engines/mortevielle/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_MORTEVIELLE
+DEFINES += -DENABLE_MORTEVIELLE=$(ENABLE_MORTEVIELLE)
+MODULES += engines/mortevielle
+endif
diff --git a/engines/neverhood/engine.mk b/engines/neverhood/engine.mk
new file mode 100644
index 0000000..52b032a
--- /dev/null
+++ b/engines/neverhood/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_NEVERHOOD
+DEFINES += -DENABLE_NEVERHOOD=$(ENABLE_NEVERHOOD)
+MODULES += engines/neverhood
+endif
diff --git a/engines/parallaction/engine.mk b/engines/parallaction/engine.mk
new file mode 100644
index 0000000..465b6fc
--- /dev/null
+++ b/engines/parallaction/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_PARALLACTION
+DEFINES += -DENABLE_PARALLACTION=$(ENABLE_PARALLACTION)
+MODULES += engines/parallaction
+endif
diff --git a/engines/pegasus/engine.mk b/engines/pegasus/engine.mk
new file mode 100644
index 0000000..60bba59
--- /dev/null
+++ b/engines/pegasus/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_PEGASUS
+DEFINES += -DENABLE_PEGASUS=$(ENABLE_PEGASUS)
+MODULES += engines/pegasus
+endif
diff --git a/engines/queen/engine.mk b/engines/queen/engine.mk
new file mode 100644
index 0000000..05f3dca
--- /dev/null
+++ b/engines/queen/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_QUEEN
+DEFINES += -DENABLE_QUEEN=$(ENABLE_QUEEN)
+MODULES += engines/queen
+endif
diff --git a/engines/saga/engine.mk b/engines/saga/engine.mk
new file mode 100644
index 0000000..a6e855b
--- /dev/null
+++ b/engines/saga/engine.mk
@@ -0,0 +1,12 @@
+ifdef ENABLE_SAGA
+DEFINES += -DENABLE_SAGA=$(ENABLE_SAGA)
+MODULES += engines/saga
+
+ifdef ENABLE_IHNM
+DEFINES += -DENABLE_IHNM
+endif
+
+ifdef ENABLE_SAGA2
+DEFINES += -DENABLE_SAGA2
+endif
+endif
diff --git a/engines/sci/engine.mk b/engines/sci/engine.mk
new file mode 100644
index 0000000..7f26a19
--- /dev/null
+++ b/engines/sci/engine.mk
@@ -0,0 +1,8 @@
+ifdef ENABLE_SCI
+DEFINES += -DENABLE_SCI=$(ENABLE_SCI)
+MODULES += engines/sci
+
+ifdef ENABLE_SCI32
+DEFINES += -DENABLE_SCI32
+endif
+endif
diff --git a/engines/scumm/engine.mk b/engines/scumm/engine.mk
new file mode 100644
index 0000000..640dfb5
--- /dev/null
+++ b/engines/scumm/engine.mk
@@ -0,0 +1,12 @@
+ifdef ENABLE_SCUMM
+DEFINES += -DENABLE_SCUMM=$(ENABLE_SCUMM)
+MODULES += engines/scumm
+
+ifdef ENABLE_SCUMM_7_8
+DEFINES += -DENABLE_SCUMM_7_8
+endif
+
+ifdef ENABLE_HE
+DEFINES += -DENABLE_HE
+endif
+endif
diff --git a/engines/sky/engine.mk b/engines/sky/engine.mk
new file mode 100644
index 0000000..182e608
--- /dev/null
+++ b/engines/sky/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_SKY
+DEFINES += -DENABLE_SKY=$(ENABLE_SKY)
+MODULES += engines/sky
+endif
diff --git a/engines/sword1/engine.mk b/engines/sword1/engine.mk
new file mode 100644
index 0000000..39f6afb
--- /dev/null
+++ b/engines/sword1/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_SWORD1
+DEFINES += -DENABLE_SWORD1=$(ENABLE_SWORD1)
+MODULES += engines/sword1
+endif
diff --git a/engines/sword2/engine.mk b/engines/sword2/engine.mk
new file mode 100644
index 0000000..5f05112
--- /dev/null
+++ b/engines/sword2/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_SWORD2
+DEFINES += -DENABLE_SWORD2=$(ENABLE_SWORD2)
+MODULES += engines/sword2
+endif
diff --git a/engines/sword25/engine.mk b/engines/sword25/engine.mk
new file mode 100644
index 0000000..32a906c
--- /dev/null
+++ b/engines/sword25/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_SWORD25
+DEFINES += -DENABLE_SWORD25=$(ENABLE_SWORD25)
+MODULES += engines/sword25
+endif
diff --git a/engines/teenagent/engine.mk b/engines/teenagent/engine.mk
new file mode 100644
index 0000000..82004eb
--- /dev/null
+++ b/engines/teenagent/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_TEENAGENT
+DEFINES += -DENABLE_TEENAGENT=$(ENABLE_TEENAGENT)
+MODULES += engines/teenagent
+endif
diff --git a/engines/testbed/engine.mk b/engines/testbed/engine.mk
new file mode 100644
index 0000000..b19db6e
--- /dev/null
+++ b/engines/testbed/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_TESTBED
+DEFINES += -DENABLE_TESTBED=$(ENABLE_TESTBED)
+MODULES += engines/testbed
+endif
diff --git a/engines/tinsel/engine.mk b/engines/tinsel/engine.mk
new file mode 100644
index 0000000..f3df46b
--- /dev/null
+++ b/engines/tinsel/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_TINSEL
+DEFINES += -DENABLE_TINSEL=$(ENABLE_TINSEL)
+MODULES += engines/tinsel
+endif
diff --git a/engines/toltecs/engine.mk b/engines/toltecs/engine.mk
new file mode 100644
index 0000000..38bf6c0
--- /dev/null
+++ b/engines/toltecs/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_TOLTECS
+DEFINES += -DENABLE_TOLTECS=$(ENABLE_TOLTECS)
+MODULES += engines/toltecs
+endif
diff --git a/engines/tony/engine.mk b/engines/tony/engine.mk
new file mode 100644
index 0000000..605f2e6
--- /dev/null
+++ b/engines/tony/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_TONY
+DEFINES += -DENABLE_TONY=$(ENABLE_TONY)
+MODULES += engines/tony
+endif
diff --git a/engines/toon/engine.mk b/engines/toon/engine.mk
new file mode 100644
index 0000000..ec8b66f
--- /dev/null
+++ b/engines/toon/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_TOON
+DEFINES += -DENABLE_TOON=$(ENABLE_TOON)
+MODULES += engines/toon
+endif
diff --git a/engines/touche/engine.mk b/engines/touche/engine.mk
new file mode 100644
index 0000000..1629a82
--- /dev/null
+++ b/engines/touche/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_TOUCHE
+DEFINES += -DENABLE_TOUCHE=$(ENABLE_TOUCHE)
+MODULES += engines/touche
+endif
diff --git a/engines/tsage/engine.mk b/engines/tsage/engine.mk
new file mode 100644
index 0000000..d734665
--- /dev/null
+++ b/engines/tsage/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_TSAGE
+DEFINES += -DENABLE_TSAGE=$(ENABLE_TSAGE)
+MODULES += engines/tsage
+endif
diff --git a/engines/tucker/engine.mk b/engines/tucker/engine.mk
new file mode 100644
index 0000000..6342af0
--- /dev/null
+++ b/engines/tucker/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_TUCKER
+DEFINES += -DENABLE_TUCKER=$(ENABLE_TUCKER)
+MODULES += engines/tucker
+endif
diff --git a/engines/wintermute/engine.mk b/engines/wintermute/engine.mk
new file mode 100644
index 0000000..145d2f7
--- /dev/null
+++ b/engines/wintermute/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_WINTERMUTE
+DEFINES += -DENABLE_WINTERMUTE=$(ENABLE_WINTERMUTE)
+MODULES += engines/wintermute
+endif
diff --git a/engines/zvision/engine.mk b/engines/zvision/engine.mk
new file mode 100644
index 0000000..be76a4d
--- /dev/null
+++ b/engines/zvision/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_ZVISION
+DEFINES += -DENABLE_ZVISION=$(ENABLE_ZVISION)
+MODULES += engines/zvision
+endif


Commit: 00c27a28f91cc2bbf512461e69c86be998462728
    https://github.com/scummvm/scummvm/commit/00c27a28f91cc2bbf512461e69c86be998462728
Author: D G Turner (digitall at scummvm.org)
Date: 2013-11-23T16:48:01-08:00

Commit Message:
BUILD: Split engines/plugins_table header down to a file per engine.

This is the third and final commit enabling fully pluggable engines.

Now providing an engine folder contains a configure.engine, engine.mk
and engine-plugin.h file, it will be picked up automatically by the
configure script.

Changed paths:
  A engines/agi/engine-plugin.h
  A engines/agos/engine-plugin.h
  A engines/avalanche/engine-plugin.h
  A engines/cge/engine-plugin.h
  A engines/cine/engine-plugin.h
  A engines/composer/engine-plugin.h
  A engines/cruise/engine-plugin.h
  A engines/draci/engine-plugin.h
  A engines/drascula/engine-plugin.h
  A engines/dreamweb/engine-plugin.h
  A engines/fullpipe/engine-plugin.h
  A engines/gob/engine-plugin.h
  A engines/groovie/engine-plugin.h
  A engines/hopkins/engine-plugin.h
  A engines/hugo/engine-plugin.h
  A engines/kyra/engine-plugin.h
  A engines/lastexpress/engine-plugin.h
  A engines/lure/engine-plugin.h
  A engines/made/engine-plugin.h
  A engines/mohawk/engine-plugin.h
  A engines/mortevielle/engine-plugin.h
  A engines/neverhood/engine-plugin.h
  A engines/parallaction/engine-plugin.h
  A engines/pegasus/engine-plugin.h
  A engines/queen/engine-plugin.h
  A engines/saga/engine-plugin.h
  A engines/sci/engine-plugin.h
  A engines/scumm/engine-plugin.h
  A engines/sky/engine-plugin.h
  A engines/sword1/engine-plugin.h
  A engines/sword2/engine-plugin.h
  A engines/sword25/engine-plugin.h
  A engines/teenagent/engine-plugin.h
  A engines/testbed/engine-plugin.h
  A engines/tinsel/engine-plugin.h
  A engines/toltecs/engine-plugin.h
  A engines/tony/engine-plugin.h
  A engines/toon/engine-plugin.h
  A engines/touche/engine-plugin.h
  A engines/tsage/engine-plugin.h
  A engines/tucker/engine-plugin.h
  A engines/wintermute/engine-plugin.h
  A engines/zvision/engine-plugin.h
  R engines/plugins_table.h
    .gitignore
    Makefile
    Makefile.common
    configure



diff --git a/.gitignore b/.gitignore
index 0fe2120..04b81dd 100644
--- a/.gitignore
+++ b/.gitignore
@@ -105,6 +105,8 @@ project.xcworkspace
 
 /plugins
 
+/engines/plugins_table.h
+
 /test/runner
 /test/runner.cpp
 /test/*.dSYM
diff --git a/Makefile b/Makefile
index 2ff67ee..2f17822 100644
--- a/Makefile
+++ b/Makefile
@@ -83,7 +83,7 @@ include $(srcdir)/Makefile.common
 
 # check if configure has been run or has been changed since last run
 ENGINE_SUBDIRS_CONFIGURE := $(wildcard $(srcdir)/engines/*/configure.engine)
-config.h config.mk: $(srcdir)/configure $(ENGINE_SUBDIRS_CONFIGURE)
+config.h config.mk engines/plugins_table.h: $(srcdir)/configure $(ENGINE_SUBDIRS_CONFIGURE)
 ifeq "$(findstring config.mk,$(MAKEFILE_LIST))" "config.mk"
 	@echo "Running $(srcdir)/configure with the last specified parameters"
 	@sleep 2
diff --git a/Makefile.common b/Makefile.common
index 41a3245..0b2f8a5 100644
--- a/Makefile.common
+++ b/Makefile.common
@@ -81,7 +81,7 @@ $(EXECUTABLE): $(OBJS)
 	$(QUIET_LINK)$(LD) $(LDFLAGS) $(PRE_OBJS_FLAGS) $+ $(POST_OBJS_FLAGS) $(LIBS) -o $@
 
 distclean: clean clean-devtools
-	$(RM) config.h config.mk config.log
+	$(RM) config.h config.mk config.log engines/plugins_table.h
 
 clean:
 	$(RM_REC) $(DEPDIRS)
diff --git a/configure b/configure
index 4825cdc..2bad89a 100755
--- a/configure
+++ b/configure
@@ -4382,3 +4382,14 @@ include \$(srcdir)/Makefile
 EOF
 
 fi
+
+echo "Creating engines/plugins_table.h"
+cat > engines/plugins_table.h << EOF
+/* This file is automatically generated by configure */
+/* DO NOT EDIT MANUALLY */
+// This file is being included by "base/plugins.cpp"
+EOF
+
+for i in $_srcdir/engines/*/engine-plugin.h; do
+	cat $i >> engines/plugins_table.h
+done
diff --git a/engines/agi/engine-plugin.h b/engines/agi/engine-plugin.h
new file mode 100644
index 0000000..962a8ca
--- /dev/null
+++ b/engines/agi/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(AGI)
+LINK_PLUGIN(AGI)
+#endif
diff --git a/engines/agos/engine-plugin.h b/engines/agos/engine-plugin.h
new file mode 100644
index 0000000..ea4e6f7
--- /dev/null
+++ b/engines/agos/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(AGOS)
+LINK_PLUGIN(AGOS)
+#endif
diff --git a/engines/avalanche/engine-plugin.h b/engines/avalanche/engine-plugin.h
new file mode 100644
index 0000000..bfe791d
--- /dev/null
+++ b/engines/avalanche/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(AVALANCHE)
+LINK_PLUGIN(AVALANCHE)
+#endif
diff --git a/engines/cge/engine-plugin.h b/engines/cge/engine-plugin.h
new file mode 100644
index 0000000..8f9c23e
--- /dev/null
+++ b/engines/cge/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(CGE)
+LINK_PLUGIN(CGE)
+#endif
diff --git a/engines/cine/engine-plugin.h b/engines/cine/engine-plugin.h
new file mode 100644
index 0000000..be38a29
--- /dev/null
+++ b/engines/cine/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(CINE)
+LINK_PLUGIN(CINE)
+#endif
diff --git a/engines/composer/engine-plugin.h b/engines/composer/engine-plugin.h
new file mode 100644
index 0000000..d06f241
--- /dev/null
+++ b/engines/composer/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(COMPOSER)
+LINK_PLUGIN(COMPOSER)
+#endif
diff --git a/engines/cruise/engine-plugin.h b/engines/cruise/engine-plugin.h
new file mode 100644
index 0000000..78fbbbd
--- /dev/null
+++ b/engines/cruise/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(CRUISE)
+LINK_PLUGIN(CRUISE)
+#endif
diff --git a/engines/draci/engine-plugin.h b/engines/draci/engine-plugin.h
new file mode 100644
index 0000000..c02afdb
--- /dev/null
+++ b/engines/draci/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(DRACI)
+LINK_PLUGIN(DRACI)
+#endif
diff --git a/engines/drascula/engine-plugin.h b/engines/drascula/engine-plugin.h
new file mode 100644
index 0000000..d0f598c
--- /dev/null
+++ b/engines/drascula/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(DRASCULA)
+LINK_PLUGIN(DRASCULA)
+#endif
diff --git a/engines/dreamweb/engine-plugin.h b/engines/dreamweb/engine-plugin.h
new file mode 100644
index 0000000..fae9e7a
--- /dev/null
+++ b/engines/dreamweb/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(DREAMWEB)
+LINK_PLUGIN(DREAMWEB)
+#endif
diff --git a/engines/fullpipe/engine-plugin.h b/engines/fullpipe/engine-plugin.h
new file mode 100644
index 0000000..ea875a7
--- /dev/null
+++ b/engines/fullpipe/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(FULLPIPE)
+LINK_PLUGIN(FULLPIPE)
+#endif
diff --git a/engines/gob/engine-plugin.h b/engines/gob/engine-plugin.h
new file mode 100644
index 0000000..86cff48
--- /dev/null
+++ b/engines/gob/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(GOB)
+LINK_PLUGIN(GOB)
+#endif
diff --git a/engines/groovie/engine-plugin.h b/engines/groovie/engine-plugin.h
new file mode 100644
index 0000000..dcb05b1
--- /dev/null
+++ b/engines/groovie/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(GROOVIE)
+LINK_PLUGIN(GROOVIE)
+#endif
diff --git a/engines/hopkins/engine-plugin.h b/engines/hopkins/engine-plugin.h
new file mode 100644
index 0000000..fe54ca1
--- /dev/null
+++ b/engines/hopkins/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(HOPKINS)
+LINK_PLUGIN(HOPKINS)
+#endif
diff --git a/engines/hugo/engine-plugin.h b/engines/hugo/engine-plugin.h
new file mode 100644
index 0000000..12b6edc
--- /dev/null
+++ b/engines/hugo/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(HUGO)
+LINK_PLUGIN(HUGO)
+#endif
diff --git a/engines/kyra/engine-plugin.h b/engines/kyra/engine-plugin.h
new file mode 100644
index 0000000..b3bcb47
--- /dev/null
+++ b/engines/kyra/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(KYRA)
+LINK_PLUGIN(KYRA)
+#endif
diff --git a/engines/lastexpress/engine-plugin.h b/engines/lastexpress/engine-plugin.h
new file mode 100644
index 0000000..2cca42f
--- /dev/null
+++ b/engines/lastexpress/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(LASTEXPRESS)
+LINK_PLUGIN(LASTEXPRESS)
+#endif
diff --git a/engines/lure/engine-plugin.h b/engines/lure/engine-plugin.h
new file mode 100644
index 0000000..a139260
--- /dev/null
+++ b/engines/lure/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(LURE)
+LINK_PLUGIN(LURE)
+#endif
diff --git a/engines/made/engine-plugin.h b/engines/made/engine-plugin.h
new file mode 100644
index 0000000..ed54447
--- /dev/null
+++ b/engines/made/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(MADE)
+LINK_PLUGIN(MADE)
+#endif
diff --git a/engines/mohawk/engine-plugin.h b/engines/mohawk/engine-plugin.h
new file mode 100644
index 0000000..d2e6979
--- /dev/null
+++ b/engines/mohawk/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(MOHAWK)
+LINK_PLUGIN(MOHAWK)
+#endif
diff --git a/engines/mortevielle/engine-plugin.h b/engines/mortevielle/engine-plugin.h
new file mode 100644
index 0000000..a0895d4
--- /dev/null
+++ b/engines/mortevielle/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(MORTEVIELLE)
+LINK_PLUGIN(MORTEVIELLE)
+#endif
diff --git a/engines/neverhood/engine-plugin.h b/engines/neverhood/engine-plugin.h
new file mode 100644
index 0000000..7857703
--- /dev/null
+++ b/engines/neverhood/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(NEVERHOOD)
+LINK_PLUGIN(NEVERHOOD)
+#endif
diff --git a/engines/parallaction/engine-plugin.h b/engines/parallaction/engine-plugin.h
new file mode 100644
index 0000000..21fb5d9
--- /dev/null
+++ b/engines/parallaction/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(PARALLACTION)
+LINK_PLUGIN(PARALLACTION)
+#endif
diff --git a/engines/pegasus/engine-plugin.h b/engines/pegasus/engine-plugin.h
new file mode 100644
index 0000000..7f9cb43
--- /dev/null
+++ b/engines/pegasus/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(PEGASUS)
+LINK_PLUGIN(PEGASUS)
+#endif
diff --git a/engines/plugins_table.h b/engines/plugins_table.h
deleted file mode 100644
index 38cd43a..0000000
--- a/engines/plugins_table.h
+++ /dev/null
@@ -1,130 +0,0 @@
-// This file is being included by "base/plugins.cpp"
-#if PLUGIN_ENABLED_STATIC(SCUMM)
-LINK_PLUGIN(SCUMM)
-#endif
-#if PLUGIN_ENABLED_STATIC(AGI)
-LINK_PLUGIN(AGI)
-#endif
-#if PLUGIN_ENABLED_STATIC(AGOS)
-LINK_PLUGIN(AGOS)
-#endif
-#if PLUGIN_ENABLED_STATIC(AVALANCHE)
-LINK_PLUGIN(AVALANCHE)
-#endif
-#if PLUGIN_ENABLED_STATIC(CGE)
-LINK_PLUGIN(CGE)
-#endif
-#if PLUGIN_ENABLED_STATIC(CINE)
-LINK_PLUGIN(CINE)
-#endif
-#if PLUGIN_ENABLED_STATIC(COMPOSER)
-LINK_PLUGIN(COMPOSER)
-#endif
-#if PLUGIN_ENABLED_STATIC(CRUISE)
-LINK_PLUGIN(CRUISE)
-#endif
-#if PLUGIN_ENABLED_STATIC(DRACI)
-LINK_PLUGIN(DRACI)
-#endif
-#if PLUGIN_ENABLED_STATIC(DRASCULA)
-LINK_PLUGIN(DRASCULA)
-#endif
-#if PLUGIN_ENABLED_STATIC(DREAMWEB)
-LINK_PLUGIN(DREAMWEB)
-#endif
-#if PLUGIN_ENABLED_STATIC(FULLPIPE)
-LINK_PLUGIN(FULLPIPE)
-#endif
-#if PLUGIN_ENABLED_STATIC(GOB)
-LINK_PLUGIN(GOB)
-#endif
-#if PLUGIN_ENABLED_STATIC(GROOVIE)
-LINK_PLUGIN(GROOVIE)
-#endif
-#if PLUGIN_ENABLED_STATIC(HOPKINS)
-LINK_PLUGIN(HOPKINS)
-#endif
-#if PLUGIN_ENABLED_STATIC(HUGO)
-LINK_PLUGIN(HUGO)
-#endif
-#if PLUGIN_ENABLED_STATIC(KYRA)
-LINK_PLUGIN(KYRA)
-#endif
-#if PLUGIN_ENABLED_STATIC(MORTEVIELLE)
-LINK_PLUGIN(MORTEVIELLE)
-#endif
-#if PLUGIN_ENABLED_STATIC(LASTEXPRESS)
-LINK_PLUGIN(LASTEXPRESS)
-#endif
-#if PLUGIN_ENABLED_STATIC(LURE)
-LINK_PLUGIN(LURE)
-#endif
-#if PLUGIN_ENABLED_STATIC(MADE)
-LINK_PLUGIN(MADE)
-#endif
-#if PLUGIN_ENABLED_STATIC(MOHAWK)
-LINK_PLUGIN(MOHAWK)
-#endif
-#if PLUGIN_ENABLED_STATIC(NEVERHOOD)
-LINK_PLUGIN(NEVERHOOD)
-#endif
-#if PLUGIN_ENABLED_STATIC(PARALLACTION)
-LINK_PLUGIN(PARALLACTION)
-#endif
-#if PLUGIN_ENABLED_STATIC(PEGASUS)
-LINK_PLUGIN(PEGASUS)
-#endif
-#if PLUGIN_ENABLED_STATIC(QUEEN)
-LINK_PLUGIN(QUEEN)
-#endif
-#if PLUGIN_ENABLED_STATIC(SAGA)
-LINK_PLUGIN(SAGA)
-#endif
-#if PLUGIN_ENABLED_STATIC(SCI)
-LINK_PLUGIN(SCI)
-#endif
-#if PLUGIN_ENABLED_STATIC(SKY)
-LINK_PLUGIN(SKY)
-#endif
-#if PLUGIN_ENABLED_STATIC(SWORD1)
-LINK_PLUGIN(SWORD1)
-#endif
-#if PLUGIN_ENABLED_STATIC(SWORD2)
-LINK_PLUGIN(SWORD2)
-#endif
-#if PLUGIN_ENABLED_STATIC(SWORD25)
-LINK_PLUGIN(SWORD25)
-#endif
-#if PLUGIN_ENABLED_STATIC(TEENAGENT)
-LINK_PLUGIN(TEENAGENT)
-#endif
-#if PLUGIN_ENABLED_STATIC(TESTBED)
-LINK_PLUGIN(TESTBED)
-#endif
-#if PLUGIN_ENABLED_STATIC(TINSEL)
-LINK_PLUGIN(TINSEL)
-#endif
-#if PLUGIN_ENABLED_STATIC(TOLTECS)
-LINK_PLUGIN(TOLTECS)
-#endif
-#if PLUGIN_ENABLED_STATIC(TONY)
-LINK_PLUGIN(TONY)
-#endif
-#if PLUGIN_ENABLED_STATIC(TOON)
-LINK_PLUGIN(TOON)
-#endif
-#if PLUGIN_ENABLED_STATIC(TSAGE)
-LINK_PLUGIN(TSAGE)
-#endif
-#if PLUGIN_ENABLED_STATIC(TOUCHE)
-LINK_PLUGIN(TOUCHE)
-#endif
-#if PLUGIN_ENABLED_STATIC(TUCKER)
-LINK_PLUGIN(TUCKER)
-#endif
-#if PLUGIN_ENABLED_STATIC(WINTERMUTE)
-LINK_PLUGIN(WINTERMUTE)
-#endif
-#if PLUGIN_ENABLED_STATIC(ZVISION)
-LINK_PLUGIN(ZVISION)
-#endif
diff --git a/engines/queen/engine-plugin.h b/engines/queen/engine-plugin.h
new file mode 100644
index 0000000..145f162
--- /dev/null
+++ b/engines/queen/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(QUEEN)
+LINK_PLUGIN(QUEEN)
+#endif
diff --git a/engines/saga/engine-plugin.h b/engines/saga/engine-plugin.h
new file mode 100644
index 0000000..d271e36
--- /dev/null
+++ b/engines/saga/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(SAGA)
+LINK_PLUGIN(SAGA)
+#endif
diff --git a/engines/sci/engine-plugin.h b/engines/sci/engine-plugin.h
new file mode 100644
index 0000000..01184e1
--- /dev/null
+++ b/engines/sci/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(SCI)
+LINK_PLUGIN(SCI)
+#endif
diff --git a/engines/scumm/engine-plugin.h b/engines/scumm/engine-plugin.h
new file mode 100644
index 0000000..be9f83a
--- /dev/null
+++ b/engines/scumm/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(SCUMM)
+LINK_PLUGIN(SCUMM)
+#endif
diff --git a/engines/sky/engine-plugin.h b/engines/sky/engine-plugin.h
new file mode 100644
index 0000000..54e7622
--- /dev/null
+++ b/engines/sky/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(SKY)
+LINK_PLUGIN(SKY)
+#endif
diff --git a/engines/sword1/engine-plugin.h b/engines/sword1/engine-plugin.h
new file mode 100644
index 0000000..4f8b9fd
--- /dev/null
+++ b/engines/sword1/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(SWORD1)
+LINK_PLUGIN(SWORD1)
+#endif
diff --git a/engines/sword2/engine-plugin.h b/engines/sword2/engine-plugin.h
new file mode 100644
index 0000000..791c358
--- /dev/null
+++ b/engines/sword2/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(SWORD2)
+LINK_PLUGIN(SWORD2)
+#endif
diff --git a/engines/sword25/engine-plugin.h b/engines/sword25/engine-plugin.h
new file mode 100644
index 0000000..526b443
--- /dev/null
+++ b/engines/sword25/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(SWORD25)
+LINK_PLUGIN(SWORD25)
+#endif
diff --git a/engines/teenagent/engine-plugin.h b/engines/teenagent/engine-plugin.h
new file mode 100644
index 0000000..1edf835
--- /dev/null
+++ b/engines/teenagent/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(TEENAGENT)
+LINK_PLUGIN(TEENAGENT)
+#endif
diff --git a/engines/testbed/engine-plugin.h b/engines/testbed/engine-plugin.h
new file mode 100644
index 0000000..8ae5687
--- /dev/null
+++ b/engines/testbed/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(TESTBED)
+LINK_PLUGIN(TESTBED)
+#endif
diff --git a/engines/tinsel/engine-plugin.h b/engines/tinsel/engine-plugin.h
new file mode 100644
index 0000000..a8046b2
--- /dev/null
+++ b/engines/tinsel/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(TINSEL)
+LINK_PLUGIN(TINSEL)
+#endif
diff --git a/engines/toltecs/engine-plugin.h b/engines/toltecs/engine-plugin.h
new file mode 100644
index 0000000..8d63209
--- /dev/null
+++ b/engines/toltecs/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(TOLTECS)
+LINK_PLUGIN(TOLTECS)
+#endif
diff --git a/engines/tony/engine-plugin.h b/engines/tony/engine-plugin.h
new file mode 100644
index 0000000..68bd31b
--- /dev/null
+++ b/engines/tony/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(TONY)
+LINK_PLUGIN(TONY)
+#endif
diff --git a/engines/toon/engine-plugin.h b/engines/toon/engine-plugin.h
new file mode 100644
index 0000000..969ac88
--- /dev/null
+++ b/engines/toon/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(TOON)
+LINK_PLUGIN(TOON)
+#endif
diff --git a/engines/touche/engine-plugin.h b/engines/touche/engine-plugin.h
new file mode 100644
index 0000000..d778ec5
--- /dev/null
+++ b/engines/touche/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(TOUCHE)
+LINK_PLUGIN(TOUCHE)
+#endif
diff --git a/engines/tsage/engine-plugin.h b/engines/tsage/engine-plugin.h
new file mode 100644
index 0000000..73711aa
--- /dev/null
+++ b/engines/tsage/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(TSAGE)
+LINK_PLUGIN(TSAGE)
+#endif
diff --git a/engines/tucker/engine-plugin.h b/engines/tucker/engine-plugin.h
new file mode 100644
index 0000000..524574c
--- /dev/null
+++ b/engines/tucker/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(TUCKER)
+LINK_PLUGIN(TUCKER)
+#endif
diff --git a/engines/wintermute/engine-plugin.h b/engines/wintermute/engine-plugin.h
new file mode 100644
index 0000000..e338020
--- /dev/null
+++ b/engines/wintermute/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(WINTERMUTE)
+LINK_PLUGIN(WINTERMUTE)
+#endif
diff --git a/engines/zvision/engine-plugin.h b/engines/zvision/engine-plugin.h
new file mode 100644
index 0000000..384a39e
--- /dev/null
+++ b/engines/zvision/engine-plugin.h
@@ -0,0 +1,3 @@
+#if PLUGIN_ENABLED_STATIC(ZVISION)
+LINK_PLUGIN(ZVISION)
+#endif


Commit: 1ac01d2333af11d403ef84dd5192abb18814e5b3
    https://github.com/scummvm/scummvm/commit/1ac01d2333af11d403ef84dd5192abb18814e5b3
Author: D G Turner (digitall at scummvm.org)
Date: 2013-11-23T16:48:01-08:00

Commit Message:
BUILD: Remove need for engine-plugin.h in engines.

This is now generated automatically by the configure script from the
engine directory names.

Changed paths:
  R engines/agi/engine-plugin.h
  R engines/agos/engine-plugin.h
  R engines/avalanche/engine-plugin.h
  R engines/cge/engine-plugin.h
  R engines/cine/engine-plugin.h
  R engines/composer/engine-plugin.h
  R engines/cruise/engine-plugin.h
  R engines/draci/engine-plugin.h
  R engines/drascula/engine-plugin.h
  R engines/dreamweb/engine-plugin.h
  R engines/fullpipe/engine-plugin.h
  R engines/gob/engine-plugin.h
  R engines/groovie/engine-plugin.h
  R engines/hopkins/engine-plugin.h
  R engines/hugo/engine-plugin.h
  R engines/kyra/engine-plugin.h
  R engines/lastexpress/engine-plugin.h
  R engines/lure/engine-plugin.h
  R engines/made/engine-plugin.h
  R engines/mohawk/engine-plugin.h
  R engines/mortevielle/engine-plugin.h
  R engines/neverhood/engine-plugin.h
  R engines/parallaction/engine-plugin.h
  R engines/pegasus/engine-plugin.h
  R engines/queen/engine-plugin.h
  R engines/saga/engine-plugin.h
  R engines/sci/engine-plugin.h
  R engines/scumm/engine-plugin.h
  R engines/sky/engine-plugin.h
  R engines/sword1/engine-plugin.h
  R engines/sword2/engine-plugin.h
  R engines/sword25/engine-plugin.h
  R engines/teenagent/engine-plugin.h
  R engines/testbed/engine-plugin.h
  R engines/tinsel/engine-plugin.h
  R engines/toltecs/engine-plugin.h
  R engines/tony/engine-plugin.h
  R engines/toon/engine-plugin.h
  R engines/touche/engine-plugin.h
  R engines/tsage/engine-plugin.h
  R engines/tucker/engine-plugin.h
  R engines/wintermute/engine-plugin.h
  R engines/zvision/engine-plugin.h
    configure



diff --git a/configure b/configure
index 2bad89a..1832383 100755
--- a/configure
+++ b/configure
@@ -4390,6 +4390,13 @@ cat > engines/plugins_table.h << EOF
 // This file is being included by "base/plugins.cpp"
 EOF
 
-for i in $_srcdir/engines/*/engine-plugin.h; do
-	cat $i >> engines/plugins_table.h
+for i in $_srcdir/engines/*; do
+	if [ -d $i ]; then
+		j=`echo ${i#$_srcdir/engines/} | tr '[:lower:]' '[:upper:]'`
+		cat >> engines/plugins_table.h << EOF
+#if PLUGIN_ENABLED_STATIC($j)
+LINK_PLUGIN($j)
+#endif
+EOF
+	fi
 done
diff --git a/engines/agi/engine-plugin.h b/engines/agi/engine-plugin.h
deleted file mode 100644
index 962a8ca..0000000
--- a/engines/agi/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(AGI)
-LINK_PLUGIN(AGI)
-#endif
diff --git a/engines/agos/engine-plugin.h b/engines/agos/engine-plugin.h
deleted file mode 100644
index ea4e6f7..0000000
--- a/engines/agos/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(AGOS)
-LINK_PLUGIN(AGOS)
-#endif
diff --git a/engines/avalanche/engine-plugin.h b/engines/avalanche/engine-plugin.h
deleted file mode 100644
index bfe791d..0000000
--- a/engines/avalanche/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(AVALANCHE)
-LINK_PLUGIN(AVALANCHE)
-#endif
diff --git a/engines/cge/engine-plugin.h b/engines/cge/engine-plugin.h
deleted file mode 100644
index 8f9c23e..0000000
--- a/engines/cge/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(CGE)
-LINK_PLUGIN(CGE)
-#endif
diff --git a/engines/cine/engine-plugin.h b/engines/cine/engine-plugin.h
deleted file mode 100644
index be38a29..0000000
--- a/engines/cine/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(CINE)
-LINK_PLUGIN(CINE)
-#endif
diff --git a/engines/composer/engine-plugin.h b/engines/composer/engine-plugin.h
deleted file mode 100644
index d06f241..0000000
--- a/engines/composer/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(COMPOSER)
-LINK_PLUGIN(COMPOSER)
-#endif
diff --git a/engines/cruise/engine-plugin.h b/engines/cruise/engine-plugin.h
deleted file mode 100644
index 78fbbbd..0000000
--- a/engines/cruise/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(CRUISE)
-LINK_PLUGIN(CRUISE)
-#endif
diff --git a/engines/draci/engine-plugin.h b/engines/draci/engine-plugin.h
deleted file mode 100644
index c02afdb..0000000
--- a/engines/draci/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(DRACI)
-LINK_PLUGIN(DRACI)
-#endif
diff --git a/engines/drascula/engine-plugin.h b/engines/drascula/engine-plugin.h
deleted file mode 100644
index d0f598c..0000000
--- a/engines/drascula/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(DRASCULA)
-LINK_PLUGIN(DRASCULA)
-#endif
diff --git a/engines/dreamweb/engine-plugin.h b/engines/dreamweb/engine-plugin.h
deleted file mode 100644
index fae9e7a..0000000
--- a/engines/dreamweb/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(DREAMWEB)
-LINK_PLUGIN(DREAMWEB)
-#endif
diff --git a/engines/fullpipe/engine-plugin.h b/engines/fullpipe/engine-plugin.h
deleted file mode 100644
index ea875a7..0000000
--- a/engines/fullpipe/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(FULLPIPE)
-LINK_PLUGIN(FULLPIPE)
-#endif
diff --git a/engines/gob/engine-plugin.h b/engines/gob/engine-plugin.h
deleted file mode 100644
index 86cff48..0000000
--- a/engines/gob/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(GOB)
-LINK_PLUGIN(GOB)
-#endif
diff --git a/engines/groovie/engine-plugin.h b/engines/groovie/engine-plugin.h
deleted file mode 100644
index dcb05b1..0000000
--- a/engines/groovie/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(GROOVIE)
-LINK_PLUGIN(GROOVIE)
-#endif
diff --git a/engines/hopkins/engine-plugin.h b/engines/hopkins/engine-plugin.h
deleted file mode 100644
index fe54ca1..0000000
--- a/engines/hopkins/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(HOPKINS)
-LINK_PLUGIN(HOPKINS)
-#endif
diff --git a/engines/hugo/engine-plugin.h b/engines/hugo/engine-plugin.h
deleted file mode 100644
index 12b6edc..0000000
--- a/engines/hugo/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(HUGO)
-LINK_PLUGIN(HUGO)
-#endif
diff --git a/engines/kyra/engine-plugin.h b/engines/kyra/engine-plugin.h
deleted file mode 100644
index b3bcb47..0000000
--- a/engines/kyra/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(KYRA)
-LINK_PLUGIN(KYRA)
-#endif
diff --git a/engines/lastexpress/engine-plugin.h b/engines/lastexpress/engine-plugin.h
deleted file mode 100644
index 2cca42f..0000000
--- a/engines/lastexpress/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(LASTEXPRESS)
-LINK_PLUGIN(LASTEXPRESS)
-#endif
diff --git a/engines/lure/engine-plugin.h b/engines/lure/engine-plugin.h
deleted file mode 100644
index a139260..0000000
--- a/engines/lure/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(LURE)
-LINK_PLUGIN(LURE)
-#endif
diff --git a/engines/made/engine-plugin.h b/engines/made/engine-plugin.h
deleted file mode 100644
index ed54447..0000000
--- a/engines/made/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(MADE)
-LINK_PLUGIN(MADE)
-#endif
diff --git a/engines/mohawk/engine-plugin.h b/engines/mohawk/engine-plugin.h
deleted file mode 100644
index d2e6979..0000000
--- a/engines/mohawk/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(MOHAWK)
-LINK_PLUGIN(MOHAWK)
-#endif
diff --git a/engines/mortevielle/engine-plugin.h b/engines/mortevielle/engine-plugin.h
deleted file mode 100644
index a0895d4..0000000
--- a/engines/mortevielle/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(MORTEVIELLE)
-LINK_PLUGIN(MORTEVIELLE)
-#endif
diff --git a/engines/neverhood/engine-plugin.h b/engines/neverhood/engine-plugin.h
deleted file mode 100644
index 7857703..0000000
--- a/engines/neverhood/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(NEVERHOOD)
-LINK_PLUGIN(NEVERHOOD)
-#endif
diff --git a/engines/parallaction/engine-plugin.h b/engines/parallaction/engine-plugin.h
deleted file mode 100644
index 21fb5d9..0000000
--- a/engines/parallaction/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(PARALLACTION)
-LINK_PLUGIN(PARALLACTION)
-#endif
diff --git a/engines/pegasus/engine-plugin.h b/engines/pegasus/engine-plugin.h
deleted file mode 100644
index 7f9cb43..0000000
--- a/engines/pegasus/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(PEGASUS)
-LINK_PLUGIN(PEGASUS)
-#endif
diff --git a/engines/queen/engine-plugin.h b/engines/queen/engine-plugin.h
deleted file mode 100644
index 145f162..0000000
--- a/engines/queen/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(QUEEN)
-LINK_PLUGIN(QUEEN)
-#endif
diff --git a/engines/saga/engine-plugin.h b/engines/saga/engine-plugin.h
deleted file mode 100644
index d271e36..0000000
--- a/engines/saga/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(SAGA)
-LINK_PLUGIN(SAGA)
-#endif
diff --git a/engines/sci/engine-plugin.h b/engines/sci/engine-plugin.h
deleted file mode 100644
index 01184e1..0000000
--- a/engines/sci/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(SCI)
-LINK_PLUGIN(SCI)
-#endif
diff --git a/engines/scumm/engine-plugin.h b/engines/scumm/engine-plugin.h
deleted file mode 100644
index be9f83a..0000000
--- a/engines/scumm/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(SCUMM)
-LINK_PLUGIN(SCUMM)
-#endif
diff --git a/engines/sky/engine-plugin.h b/engines/sky/engine-plugin.h
deleted file mode 100644
index 54e7622..0000000
--- a/engines/sky/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(SKY)
-LINK_PLUGIN(SKY)
-#endif
diff --git a/engines/sword1/engine-plugin.h b/engines/sword1/engine-plugin.h
deleted file mode 100644
index 4f8b9fd..0000000
--- a/engines/sword1/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(SWORD1)
-LINK_PLUGIN(SWORD1)
-#endif
diff --git a/engines/sword2/engine-plugin.h b/engines/sword2/engine-plugin.h
deleted file mode 100644
index 791c358..0000000
--- a/engines/sword2/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(SWORD2)
-LINK_PLUGIN(SWORD2)
-#endif
diff --git a/engines/sword25/engine-plugin.h b/engines/sword25/engine-plugin.h
deleted file mode 100644
index 526b443..0000000
--- a/engines/sword25/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(SWORD25)
-LINK_PLUGIN(SWORD25)
-#endif
diff --git a/engines/teenagent/engine-plugin.h b/engines/teenagent/engine-plugin.h
deleted file mode 100644
index 1edf835..0000000
--- a/engines/teenagent/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(TEENAGENT)
-LINK_PLUGIN(TEENAGENT)
-#endif
diff --git a/engines/testbed/engine-plugin.h b/engines/testbed/engine-plugin.h
deleted file mode 100644
index 8ae5687..0000000
--- a/engines/testbed/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(TESTBED)
-LINK_PLUGIN(TESTBED)
-#endif
diff --git a/engines/tinsel/engine-plugin.h b/engines/tinsel/engine-plugin.h
deleted file mode 100644
index a8046b2..0000000
--- a/engines/tinsel/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(TINSEL)
-LINK_PLUGIN(TINSEL)
-#endif
diff --git a/engines/toltecs/engine-plugin.h b/engines/toltecs/engine-plugin.h
deleted file mode 100644
index 8d63209..0000000
--- a/engines/toltecs/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(TOLTECS)
-LINK_PLUGIN(TOLTECS)
-#endif
diff --git a/engines/tony/engine-plugin.h b/engines/tony/engine-plugin.h
deleted file mode 100644
index 68bd31b..0000000
--- a/engines/tony/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(TONY)
-LINK_PLUGIN(TONY)
-#endif
diff --git a/engines/toon/engine-plugin.h b/engines/toon/engine-plugin.h
deleted file mode 100644
index 969ac88..0000000
--- a/engines/toon/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(TOON)
-LINK_PLUGIN(TOON)
-#endif
diff --git a/engines/touche/engine-plugin.h b/engines/touche/engine-plugin.h
deleted file mode 100644
index d778ec5..0000000
--- a/engines/touche/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(TOUCHE)
-LINK_PLUGIN(TOUCHE)
-#endif
diff --git a/engines/tsage/engine-plugin.h b/engines/tsage/engine-plugin.h
deleted file mode 100644
index 73711aa..0000000
--- a/engines/tsage/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(TSAGE)
-LINK_PLUGIN(TSAGE)
-#endif
diff --git a/engines/tucker/engine-plugin.h b/engines/tucker/engine-plugin.h
deleted file mode 100644
index 524574c..0000000
--- a/engines/tucker/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(TUCKER)
-LINK_PLUGIN(TUCKER)
-#endif
diff --git a/engines/wintermute/engine-plugin.h b/engines/wintermute/engine-plugin.h
deleted file mode 100644
index e338020..0000000
--- a/engines/wintermute/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(WINTERMUTE)
-LINK_PLUGIN(WINTERMUTE)
-#endif
diff --git a/engines/zvision/engine-plugin.h b/engines/zvision/engine-plugin.h
deleted file mode 100644
index 384a39e..0000000
--- a/engines/zvision/engine-plugin.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#if PLUGIN_ENABLED_STATIC(ZVISION)
-LINK_PLUGIN(ZVISION)
-#endif


Commit: ef85456859e466adc8913041e4f31809485c45ab
    https://github.com/scummvm/scummvm/commit/ef85456859e466adc8913041e4f31809485c45ab
Author: D G Turner (digitall at scummvm.org)
Date: 2013-11-23T16:48:01-08:00

Commit Message:
BUILD: Remove need for engine.mk in each engine directory.

Each engine now only has to provide a single configure.engine file
adding the engine into the configure script, which then produces the
required other files automatically.

Changed paths:
  R engines/agi/engine.mk
  R engines/agos/engine.mk
  R engines/avalanche/engine.mk
  R engines/cge/engine.mk
  R engines/cine/engine.mk
  R engines/composer/engine.mk
  R engines/cruise/engine.mk
  R engines/draci/engine.mk
  R engines/drascula/engine.mk
  R engines/dreamweb/engine.mk
  R engines/fullpipe/engine.mk
  R engines/gob/engine.mk
  R engines/groovie/engine.mk
  R engines/hopkins/engine.mk
  R engines/hugo/engine.mk
  R engines/kyra/engine.mk
  R engines/lastexpress/engine.mk
  R engines/lure/engine.mk
  R engines/made/engine.mk
  R engines/mohawk/engine.mk
  R engines/mortevielle/engine.mk
  R engines/neverhood/engine.mk
  R engines/parallaction/engine.mk
  R engines/pegasus/engine.mk
  R engines/queen/engine.mk
  R engines/saga/engine.mk
  R engines/sci/engine.mk
  R engines/scumm/engine.mk
  R engines/sky/engine.mk
  R engines/sword1/engine.mk
  R engines/sword2/engine.mk
  R engines/sword25/engine.mk
  R engines/teenagent/engine.mk
  R engines/testbed/engine.mk
  R engines/tinsel/engine.mk
  R engines/toltecs/engine.mk
  R engines/tony/engine.mk
  R engines/toon/engine.mk
  R engines/touche/engine.mk
  R engines/tsage/engine.mk
  R engines/tucker/engine.mk
  R engines/wintermute/engine.mk
  R engines/zvision/engine.mk
    .gitignore
    Makefile
    Makefile.common
    configure



diff --git a/.gitignore b/.gitignore
index 04b81dd..469f22d 100644
--- a/.gitignore
+++ b/.gitignore
@@ -106,6 +106,7 @@ project.xcworkspace
 /plugins
 
 /engines/plugins_table.h
+/engines/engines.mk
 
 /test/runner
 /test/runner.cpp
diff --git a/Makefile b/Makefile
index 2f17822..45f50f9 100644
--- a/Makefile
+++ b/Makefile
@@ -83,7 +83,7 @@ include $(srcdir)/Makefile.common
 
 # check if configure has been run or has been changed since last run
 ENGINE_SUBDIRS_CONFIGURE := $(wildcard $(srcdir)/engines/*/configure.engine)
-config.h config.mk engines/plugins_table.h: $(srcdir)/configure $(ENGINE_SUBDIRS_CONFIGURE)
+config.h config.mk engines/plugins_table.h engines/engines.mk: $(srcdir)/configure $(ENGINE_SUBDIRS_CONFIGURE)
 ifeq "$(findstring config.mk,$(MAKEFILE_LIST))" "config.mk"
 	@echo "Running $(srcdir)/configure with the last specified parameters"
 	@sleep 2
diff --git a/Makefile.common b/Makefile.common
index 0b2f8a5..b56300a 100644
--- a/Makefile.common
+++ b/Makefile.common
@@ -16,9 +16,7 @@ all: $(EXECUTABLE) plugins
 PLUGINS :=
 MODULES := test devtools base $(MODULES)
 
-ENGINE_SUBDIRS_MK := $(wildcard $(srcdir)/engines/*/engine.mk)
-# Include the build instructions for all engines
--include $(ENGINE_SUBDIRS_MK)
+-include engines/engines.mk
 
 # After the game specific modules follow the shared modules
 MODULES += \
@@ -81,7 +79,7 @@ $(EXECUTABLE): $(OBJS)
 	$(QUIET_LINK)$(LD) $(LDFLAGS) $(PRE_OBJS_FLAGS) $+ $(POST_OBJS_FLAGS) $(LIBS) -o $@
 
 distclean: clean clean-devtools
-	$(RM) config.h config.mk config.log engines/plugins_table.h
+	$(RM) config.h config.mk config.log engines/engines.mk engines/plugins_table.h
 
 clean:
 	$(RM_REC) $(DEPDIRS)
@@ -149,7 +147,7 @@ endif
 # recreate them (which it can't), and in particular from looking for potential
 # source files. This can save quite a bit of disk access time.
 .PHONY: $(wildcard $(addsuffix /*.d,$(DEPDIRS))) $(addprefix $(srcdir)/, $(addsuffix /module.mk,$(MODULES))) \
-	$(srcdir)/$(port_mk) $(srcdir)/rules.mk $ENGINE_SUBDIRS_MK
+	$(srcdir)/$(port_mk) $(srcdir)/rules.mk
 
 ######################################################################
 # Get the current version information
diff --git a/configure b/configure
index 1832383..bf8649a 100755
--- a/configure
+++ b/configure
@@ -4383,6 +4383,40 @@ EOF
 
 fi
 
+echo "Creating engines/engines.mk"
+cat > engines/engines.mk << EOF
+# This file is automatically generated by configure
+# DO NOT EDIT MANUALLY
+# This file is being included by "Makefile.common"
+EOF
+
+for engine in $_engines; do
+	j=`echo $engine | tr '[:lower:]' '[:upper:]'`
+	if test "`get_engine_sub $engine`" = "no" ; then
+		# main engine
+		cat >> engines/engines.mk << EOF
+
+ifdef ENABLE_$j
+DEFINES += -DENABLE_$j=\$(ENABLE_$j)
+MODULES += engines/$engine
+EOF
+
+	for subeng in `get_engine_subengines $engine` ; do
+		k=`echo $subeng | tr '[:lower:]' '[:upper:]'`
+		cat >> engines/engines.mk << EOF
+
+ifdef ENABLE_$k
+DEFINES += -DENABLE_$k
+endif
+EOF
+	done
+
+	cat >> engines/engines.mk << EOF
+endif
+EOF
+	fi
+done
+
 echo "Creating engines/plugins_table.h"
 cat > engines/plugins_table.h << EOF
 /* This file is automatically generated by configure */
@@ -4390,9 +4424,9 @@ cat > engines/plugins_table.h << EOF
 // This file is being included by "base/plugins.cpp"
 EOF
 
-for i in $_srcdir/engines/*; do
-	if [ -d $i ]; then
-		j=`echo ${i#$_srcdir/engines/} | tr '[:lower:]' '[:upper:]'`
+for engine in $_engines; do
+	if test "`get_engine_sub $engine`" = "no" ; then
+		j=`echo $engine | tr '[:lower:]' '[:upper:]'`
 		cat >> engines/plugins_table.h << EOF
 #if PLUGIN_ENABLED_STATIC($j)
 LINK_PLUGIN($j)
diff --git a/engines/agi/engine.mk b/engines/agi/engine.mk
deleted file mode 100644
index 18963fd..0000000
--- a/engines/agi/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_AGI
-DEFINES += -DENABLE_AGI=$(ENABLE_AGI)
-MODULES += engines/agi
-endif
diff --git a/engines/agos/engine.mk b/engines/agos/engine.mk
deleted file mode 100644
index ba60a78..0000000
--- a/engines/agos/engine.mk
+++ /dev/null
@@ -1,8 +0,0 @@
-ifdef ENABLE_AGOS
-DEFINES += -DENABLE_AGOS=$(ENABLE_AGOS)
-MODULES += engines/agos
-
-ifdef ENABLE_AGOS2
-DEFINES += -DENABLE_AGOS2
-endif
-endif
diff --git a/engines/avalanche/engine.mk b/engines/avalanche/engine.mk
deleted file mode 100644
index 17356ee..0000000
--- a/engines/avalanche/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_AVALANCHE
-DEFINES += -DENABLE_AVALANCHE=$(ENABLE_AVALANCHE)
-MODULES += engines/avalanche
-endif
diff --git a/engines/cge/engine.mk b/engines/cge/engine.mk
deleted file mode 100644
index c71f4e0..0000000
--- a/engines/cge/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_CGE
-DEFINES += -DENABLE_CGE=$(ENABLE_CGE)
-MODULES += engines/cge
-endif
diff --git a/engines/cine/engine.mk b/engines/cine/engine.mk
deleted file mode 100644
index a32c319..0000000
--- a/engines/cine/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_CINE
-DEFINES += -DENABLE_CINE=$(ENABLE_CINE)
-MODULES += engines/cine
-endif
diff --git a/engines/composer/engine.mk b/engines/composer/engine.mk
deleted file mode 100644
index b444021..0000000
--- a/engines/composer/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_COMPOSER
-DEFINES += -DENABLE_COMPOSER=$(ENABLE_COMPOSER)
-MODULES += engines/composer
-endif
diff --git a/engines/cruise/engine.mk b/engines/cruise/engine.mk
deleted file mode 100644
index ac37c61..0000000
--- a/engines/cruise/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_CRUISE
-DEFINES += -DENABLE_CRUISE=$(ENABLE_CRUISE)
-MODULES += engines/cruise
-endif
diff --git a/engines/draci/engine.mk b/engines/draci/engine.mk
deleted file mode 100644
index 81ccc3f..0000000
--- a/engines/draci/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_DRACI
-DEFINES += -DENABLE_DRACI=$(ENABLE_DRACI)
-MODULES += engines/draci
-endif
diff --git a/engines/drascula/engine.mk b/engines/drascula/engine.mk
deleted file mode 100644
index ca4f6c9..0000000
--- a/engines/drascula/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_DRASCULA
-DEFINES += -DENABLE_DRASCULA=$(ENABLE_DRASCULA)
-MODULES += engines/drascula
-endif
diff --git a/engines/dreamweb/engine.mk b/engines/dreamweb/engine.mk
deleted file mode 100644
index 088fcca..0000000
--- a/engines/dreamweb/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_DREAMWEB
-DEFINES += -DENABLE_DREAMWEB=$(ENABLE_DREAMWEB)
-MODULES += engines/dreamweb
-endif
diff --git a/engines/fullpipe/engine.mk b/engines/fullpipe/engine.mk
deleted file mode 100644
index 7aeec54..0000000
--- a/engines/fullpipe/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_FULLPIPE
-DEFINES += -DENABLE_FULLPIPE=$(ENABLE_FULLPIPE)
-MODULES += engines/fullpipe
-endif
diff --git a/engines/gob/engine.mk b/engines/gob/engine.mk
deleted file mode 100644
index c78e7dd..0000000
--- a/engines/gob/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_GOB
-DEFINES += -DENABLE_GOB=$(ENABLE_GOB)
-MODULES += engines/gob
-endif
diff --git a/engines/groovie/engine.mk b/engines/groovie/engine.mk
deleted file mode 100644
index a209860..0000000
--- a/engines/groovie/engine.mk
+++ /dev/null
@@ -1,8 +0,0 @@
-ifdef ENABLE_GROOVIE
-DEFINES += -DENABLE_GROOVIE=$(ENABLE_GROOVIE)
-MODULES += engines/groovie
-
-ifdef ENABLE_GROOVIE2
-DEFINES += -DENABLE_GROOVIE2
-endif
-endif
diff --git a/engines/hopkins/engine.mk b/engines/hopkins/engine.mk
deleted file mode 100644
index ac2281c..0000000
--- a/engines/hopkins/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_HOPKINS
-DEFINES += -DENABLE_HOPKINS=$(ENABLE_HOPKINS)
-MODULES += engines/hopkins
-endif
diff --git a/engines/hugo/engine.mk b/engines/hugo/engine.mk
deleted file mode 100644
index a6ca531..0000000
--- a/engines/hugo/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_HUGO
-DEFINES += -DENABLE_HUGO=$(ENABLE_HUGO)
-MODULES += engines/hugo
-endif
diff --git a/engines/kyra/engine.mk b/engines/kyra/engine.mk
deleted file mode 100644
index a2bfce3..0000000
--- a/engines/kyra/engine.mk
+++ /dev/null
@@ -1,12 +0,0 @@
-ifdef ENABLE_KYRA
-DEFINES += -DENABLE_KYRA=$(ENABLE_KYRA)
-MODULES += engines/kyra
-
-ifdef ENABLE_LOL
-DEFINES += -DENABLE_LOL
-endif
-
-ifdef ENABLE_EOB
-DEFINES += -DENABLE_EOB
-endif
-endif
diff --git a/engines/lastexpress/engine.mk b/engines/lastexpress/engine.mk
deleted file mode 100644
index 6e0ba3b..0000000
--- a/engines/lastexpress/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_LASTEXPRESS
-DEFINES += -DENABLE_LASTEXPRESS=$(ENABLE_LASTEXPRESS)
-MODULES += engines/lastexpress
-endif
diff --git a/engines/lure/engine.mk b/engines/lure/engine.mk
deleted file mode 100644
index 62be295..0000000
--- a/engines/lure/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_LURE
-DEFINES += -DENABLE_LURE=$(ENABLE_LURE)
-MODULES += engines/lure
-endif
diff --git a/engines/made/engine.mk b/engines/made/engine.mk
deleted file mode 100644
index 8fd832c..0000000
--- a/engines/made/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_MADE
-DEFINES += -DENABLE_MADE=$(ENABLE_MADE)
-MODULES += engines/made
-endif
diff --git a/engines/mohawk/engine.mk b/engines/mohawk/engine.mk
deleted file mode 100644
index e9474b5..0000000
--- a/engines/mohawk/engine.mk
+++ /dev/null
@@ -1,16 +0,0 @@
-ifdef ENABLE_MOHAWK
-DEFINES += -DENABLE_MOHAWK=$(ENABLE_MOHAWK)
-MODULES += engines/mohawk
-
-ifdef ENABLE_CSTIME
-DEFINES += -DENABLE_CSTIME
-endif
-
-ifdef ENABLE_MYST
-DEFINES += -DENABLE_MYST
-endif
-
-ifdef ENABLE_RIVEN
-DEFINES += -DENABLE_RIVEN
-endif
-endif
diff --git a/engines/mortevielle/engine.mk b/engines/mortevielle/engine.mk
deleted file mode 100644
index 4232dec..0000000
--- a/engines/mortevielle/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_MORTEVIELLE
-DEFINES += -DENABLE_MORTEVIELLE=$(ENABLE_MORTEVIELLE)
-MODULES += engines/mortevielle
-endif
diff --git a/engines/neverhood/engine.mk b/engines/neverhood/engine.mk
deleted file mode 100644
index 52b032a..0000000
--- a/engines/neverhood/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_NEVERHOOD
-DEFINES += -DENABLE_NEVERHOOD=$(ENABLE_NEVERHOOD)
-MODULES += engines/neverhood
-endif
diff --git a/engines/parallaction/engine.mk b/engines/parallaction/engine.mk
deleted file mode 100644
index 465b6fc..0000000
--- a/engines/parallaction/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_PARALLACTION
-DEFINES += -DENABLE_PARALLACTION=$(ENABLE_PARALLACTION)
-MODULES += engines/parallaction
-endif
diff --git a/engines/pegasus/engine.mk b/engines/pegasus/engine.mk
deleted file mode 100644
index 60bba59..0000000
--- a/engines/pegasus/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_PEGASUS
-DEFINES += -DENABLE_PEGASUS=$(ENABLE_PEGASUS)
-MODULES += engines/pegasus
-endif
diff --git a/engines/queen/engine.mk b/engines/queen/engine.mk
deleted file mode 100644
index 05f3dca..0000000
--- a/engines/queen/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_QUEEN
-DEFINES += -DENABLE_QUEEN=$(ENABLE_QUEEN)
-MODULES += engines/queen
-endif
diff --git a/engines/saga/engine.mk b/engines/saga/engine.mk
deleted file mode 100644
index a6e855b..0000000
--- a/engines/saga/engine.mk
+++ /dev/null
@@ -1,12 +0,0 @@
-ifdef ENABLE_SAGA
-DEFINES += -DENABLE_SAGA=$(ENABLE_SAGA)
-MODULES += engines/saga
-
-ifdef ENABLE_IHNM
-DEFINES += -DENABLE_IHNM
-endif
-
-ifdef ENABLE_SAGA2
-DEFINES += -DENABLE_SAGA2
-endif
-endif
diff --git a/engines/sci/engine.mk b/engines/sci/engine.mk
deleted file mode 100644
index 7f26a19..0000000
--- a/engines/sci/engine.mk
+++ /dev/null
@@ -1,8 +0,0 @@
-ifdef ENABLE_SCI
-DEFINES += -DENABLE_SCI=$(ENABLE_SCI)
-MODULES += engines/sci
-
-ifdef ENABLE_SCI32
-DEFINES += -DENABLE_SCI32
-endif
-endif
diff --git a/engines/scumm/engine.mk b/engines/scumm/engine.mk
deleted file mode 100644
index 640dfb5..0000000
--- a/engines/scumm/engine.mk
+++ /dev/null
@@ -1,12 +0,0 @@
-ifdef ENABLE_SCUMM
-DEFINES += -DENABLE_SCUMM=$(ENABLE_SCUMM)
-MODULES += engines/scumm
-
-ifdef ENABLE_SCUMM_7_8
-DEFINES += -DENABLE_SCUMM_7_8
-endif
-
-ifdef ENABLE_HE
-DEFINES += -DENABLE_HE
-endif
-endif
diff --git a/engines/sky/engine.mk b/engines/sky/engine.mk
deleted file mode 100644
index 182e608..0000000
--- a/engines/sky/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_SKY
-DEFINES += -DENABLE_SKY=$(ENABLE_SKY)
-MODULES += engines/sky
-endif
diff --git a/engines/sword1/engine.mk b/engines/sword1/engine.mk
deleted file mode 100644
index 39f6afb..0000000
--- a/engines/sword1/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_SWORD1
-DEFINES += -DENABLE_SWORD1=$(ENABLE_SWORD1)
-MODULES += engines/sword1
-endif
diff --git a/engines/sword2/engine.mk b/engines/sword2/engine.mk
deleted file mode 100644
index 5f05112..0000000
--- a/engines/sword2/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_SWORD2
-DEFINES += -DENABLE_SWORD2=$(ENABLE_SWORD2)
-MODULES += engines/sword2
-endif
diff --git a/engines/sword25/engine.mk b/engines/sword25/engine.mk
deleted file mode 100644
index 32a906c..0000000
--- a/engines/sword25/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_SWORD25
-DEFINES += -DENABLE_SWORD25=$(ENABLE_SWORD25)
-MODULES += engines/sword25
-endif
diff --git a/engines/teenagent/engine.mk b/engines/teenagent/engine.mk
deleted file mode 100644
index 82004eb..0000000
--- a/engines/teenagent/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_TEENAGENT
-DEFINES += -DENABLE_TEENAGENT=$(ENABLE_TEENAGENT)
-MODULES += engines/teenagent
-endif
diff --git a/engines/testbed/engine.mk b/engines/testbed/engine.mk
deleted file mode 100644
index b19db6e..0000000
--- a/engines/testbed/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_TESTBED
-DEFINES += -DENABLE_TESTBED=$(ENABLE_TESTBED)
-MODULES += engines/testbed
-endif
diff --git a/engines/tinsel/engine.mk b/engines/tinsel/engine.mk
deleted file mode 100644
index f3df46b..0000000
--- a/engines/tinsel/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_TINSEL
-DEFINES += -DENABLE_TINSEL=$(ENABLE_TINSEL)
-MODULES += engines/tinsel
-endif
diff --git a/engines/toltecs/engine.mk b/engines/toltecs/engine.mk
deleted file mode 100644
index 38bf6c0..0000000
--- a/engines/toltecs/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_TOLTECS
-DEFINES += -DENABLE_TOLTECS=$(ENABLE_TOLTECS)
-MODULES += engines/toltecs
-endif
diff --git a/engines/tony/engine.mk b/engines/tony/engine.mk
deleted file mode 100644
index 605f2e6..0000000
--- a/engines/tony/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_TONY
-DEFINES += -DENABLE_TONY=$(ENABLE_TONY)
-MODULES += engines/tony
-endif
diff --git a/engines/toon/engine.mk b/engines/toon/engine.mk
deleted file mode 100644
index ec8b66f..0000000
--- a/engines/toon/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_TOON
-DEFINES += -DENABLE_TOON=$(ENABLE_TOON)
-MODULES += engines/toon
-endif
diff --git a/engines/touche/engine.mk b/engines/touche/engine.mk
deleted file mode 100644
index 1629a82..0000000
--- a/engines/touche/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_TOUCHE
-DEFINES += -DENABLE_TOUCHE=$(ENABLE_TOUCHE)
-MODULES += engines/touche
-endif
diff --git a/engines/tsage/engine.mk b/engines/tsage/engine.mk
deleted file mode 100644
index d734665..0000000
--- a/engines/tsage/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_TSAGE
-DEFINES += -DENABLE_TSAGE=$(ENABLE_TSAGE)
-MODULES += engines/tsage
-endif
diff --git a/engines/tucker/engine.mk b/engines/tucker/engine.mk
deleted file mode 100644
index 6342af0..0000000
--- a/engines/tucker/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_TUCKER
-DEFINES += -DENABLE_TUCKER=$(ENABLE_TUCKER)
-MODULES += engines/tucker
-endif
diff --git a/engines/wintermute/engine.mk b/engines/wintermute/engine.mk
deleted file mode 100644
index 145d2f7..0000000
--- a/engines/wintermute/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_WINTERMUTE
-DEFINES += -DENABLE_WINTERMUTE=$(ENABLE_WINTERMUTE)
-MODULES += engines/wintermute
-endif
diff --git a/engines/zvision/engine.mk b/engines/zvision/engine.mk
deleted file mode 100644
index be76a4d..0000000
--- a/engines/zvision/engine.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-ifdef ENABLE_ZVISION
-DEFINES += -DENABLE_ZVISION=$(ENABLE_ZVISION)
-MODULES += engines/zvision
-endif


Commit: 6e29e1abeefb998c97df14c6971c69822ead7959
    https://github.com/scummvm/scummvm/commit/6e29e1abeefb998c97df14c6971c69822ead7959
Author: Johannes Schickel (lordhoto at scummvm.org)
Date: 2013-11-23T16:48:01-08:00

Commit Message:
DEVTOOLS: Adapt create_project for new configure.engine files.

I could not try any generated project files since I do not have access to
the IDEs.

Changed paths:
    devtools/create_project/create_project.cpp
    devtools/create_project/create_project.h



diff --git a/devtools/create_project/create_project.cpp b/devtools/create_project/create_project.cpp
index e013377..ad3160d 100644
--- a/devtools/create_project/create_project.cpp
+++ b/devtools/create_project/create_project.cpp
@@ -81,22 +81,6 @@ std::string unifyPath(const std::string &path);
  * @param exe Name of the executable.
  */
 void displayHelp(const char *exe);
-
-/**
- * Structure for describing an FSNode. This is a very minimalistic
- * description, which includes everything we need.
- * It only contains the name of the node and whether it is a directory
- * or not.
- */
-struct FSNode {
-	FSNode() : name(), isDirectory(false) {}
-	FSNode(const std::string &n, bool iD) : name(n), isDirectory(iD) {}
-
-	std::string name; ///< Name of the file system node
-	bool isDirectory; ///< Whether it is a directory or not
-};
-
-typedef std::list<FSNode> FileList;
 } // End of anonymous namespace
 
 enum ProjectType {
@@ -128,7 +112,7 @@ int main(int argc, char *argv[]) {
 	setup.filePrefix = setup.srcDir;
 	setup.outputDir = '.';
 
-	setup.engines = parseConfigure(setup.srcDir);
+	setup.engines = parseEngines(setup.srcDir);
 
 	if (setup.engines.empty()) {
 		std::cout << "WARNING: No engines found in configure file or configure file missing in \"" << setup.srcDir << "\"\n";
@@ -672,47 +656,51 @@ void displayHelp(const char *exe) {
 }
 
 /**
- * Try to parse a given line and create an engine definition
- * out of the result.
- *
- * This may take *any* input line, when the line is not used
- * to define an engine the result of the function will be "false".
+ * Parse the configure.engine file of a given engine directory and return a
+ * list of all defined engines.
  *
- * Note that the contents of "engine" are undefined, when this
- * function returns "false".
+ * @param engineDir The directory of the engine.
+ * @return The list of all defined engines.
+ */
+EngineDescList parseEngineConfigure(const std::string &engineDir);
+
+/**
+ * Compares two FSNode entries in a strict-weak fashion based on the name.
  *
- * @param line Text input line.
- * @param engine Reference to an object, where the engine information
- *               is to be stored in.
- * @return "true", when parsing succeeded, "false" otherwise.
+ * @param left  The first operand.
+ * @param right The second operand.
+ * @return "true" when the name of the left operand is strictly smaller than
+ *         the name of the second operand. "false" otherwise.
  */
-bool parseEngine(const std::string &line, EngineDesc &engine);
+bool compareFSNode(const CreateProjectTool::FSNode &left, const CreateProjectTool::FSNode &right);
 } // End of anonymous namespace
 
-EngineDescList parseConfigure(const std::string &srcDir) {
-	std::string configureFile = srcDir + "/engines/configure.engines";
+EngineDescList parseEngines(const std::string &srcDir) {
+	using CreateProjectTool::FileList;
+	using CreateProjectTool::listDirectory;
 
-	std::ifstream configure(configureFile.c_str());
-	if (!configure)
-		return EngineDescList();
+	EngineDescList engineList;
 
-	std::string line;
-	EngineDescList engines;
+	FileList engineFiles = listDirectory(srcDir + "/engines/");
 
-	for (;;) {
-		std::getline(configure, line);
-		if (configure.eof())
-			break;
+	// Sort file list alphabetically this allows for a nicer order in
+	// --list-engines output, for example.
+	engineFiles.sort(&compareFSNode);
 
-		if (configure.fail())
-			error("Failed while reading from " + configureFile);
+	for (FileList::const_iterator i = engineFiles.begin(), end = engineFiles.end(); i != end; ++i) {
+		// Each engine requires its own sub directory thus we will skip all
+		// non directory file nodes here.
+		if (!i->isDirectory) {
+			continue;
+		}
 
-		EngineDesc desc;
-		if (parseEngine(line, desc))
-			engines.push_back(desc);
+		// Retrieve all engines defined in this sub directory and add them to
+		// the list of all engines.
+		EngineDescList list = parseEngineConfigure(srcDir + "/engines/" + i->name);
+		engineList.splice(engineList.end(), list);
 	}
 
-	return engines;
+	return engineList;
 }
 
 bool isSubEngine(const std::string &name, const EngineDescList &engines) {
@@ -777,6 +765,21 @@ StringList getEngineDefines(const EngineDescList &engines) {
 }
 
 namespace {
+/**
+ * Try to parse a given line and create an engine definition
+ * out of the result.
+ *
+ * This may take *any* input line, when the line is not used
+ * to define an engine the result of the function will be "false".
+ *
+ * Note that the contents of "engine" are undefined, when this
+ * function returns "false".
+ *
+ * @param line Text input line.
+ * @param engine Reference to an object, where the engine information
+ *               is to be stored in.
+ * @return "true", when parsing succeeded, "false" otherwise.
+ */
 bool parseEngine(const std::string &line, EngineDesc &engine) {
 	// Format:
 	// add_engine engine_name "Readable Description" enable_default ["SubEngineList"]
@@ -799,6 +802,36 @@ bool parseEngine(const std::string &line, EngineDesc &engine) {
 
 	return true;
 }
+
+EngineDescList parseEngineConfigure(const std::string &engineDir) {
+	std::string configureFile = engineDir + "/configure.engine";
+
+	std::ifstream configure(configureFile.c_str());
+	if (!configure)
+		return EngineDescList();
+
+	std::string line;
+	EngineDescList engines;
+
+	for (;;) {
+		std::getline(configure, line);
+		if (configure.eof())
+			break;
+
+		if (configure.fail())
+			error("Failed while reading from " + configureFile);
+
+		EngineDesc desc;
+		if (parseEngine(line, desc))
+			engines.push_back(desc);
+	}
+
+	return engines;
+}
+
+bool compareFSNode(const CreateProjectTool::FSNode &left, const CreateProjectTool::FSNode &right) {
+	return left.name < right.name;
+}
 } // End of anonymous namespace
 
 TokenList tokenize(const std::string &input, char separator) {
@@ -1048,13 +1081,6 @@ bool compareNodes(const FileNode *l, const FileNode *r) {
 	}
 }
 
-/**
- * Returns a list of all files and directories in the specified
- * path.
- *
- * @param dir Directory which should be listed.
- * @return List of all children.
- */
 FileList listDirectory(const std::string &dir) {
 	FileList result;
 #ifdef USE_WIN32_API
@@ -1242,6 +1268,12 @@ void ProjectProvider::createProject(BuildSetup &setup) {
 
 	// Create other misc. build files
 	createOtherBuildFiles(setup);
+
+	// In case we create the main ScummVM project files we will need to
+	// generate engines/plugins_table.h too.
+	if (!setup.tests && !setup.devTools) {
+		createEnginePluginsTable(setup);
+	}
 }
 
 ProjectProvider::UUIDMap ProjectProvider::createUUIDMap(const BuildSetup &setup) const {
@@ -1569,6 +1601,33 @@ void ProjectProvider::createModuleList(const std::string &moduleDir, const Strin
 		error("Malformed file " + moduleMkFile);
 }
 
+void ProjectProvider::createEnginePluginsTable(const BuildSetup &setup) {
+	const std::string enginePluginsTableFile = setup.outputDir + "/engines/plugins_table.h";
+	std::ofstream enginePluginsTable(enginePluginsTableFile.c_str());
+	if (!enginePluginsTable) {
+		error("Could not open \"" + enginePluginsTableFile + "\" for writing");
+	}
+
+	enginePluginsTable << "/* This file is automatically generated by create_project */\n"
+	                   << "/* DO NOT EDIT MANUALLY */\n"
+	                   << "// This file is being included by \"base/plugins.cpp\"\n";
+
+	for (EngineDescList::const_iterator i = setup.engines.begin(), end = setup.engines.end(); i != end; ++i) {
+		// We ignore all sub engines here because they require no special
+		// handling.
+		if (isSubEngine(i->name, setup.engines)) {
+			continue;
+		}
+
+		// Make the engine name all uppercase.
+		std::string engineName;
+		std::transform(i->name.begin(), i->name.end(), std::back_inserter(engineName), toupper);
+
+		enginePluginsTable << "#if PLUGIN_ENABLED_STATIC(" << engineName << ")\n"
+		                   << "LINK_PLUGIN(" << engineName << ")\n"
+		                   << "#endif\n";
+	}
+}
 } // End of anonymous namespace
 
 void error(const std::string &message) {
diff --git a/devtools/create_project/create_project.h b/devtools/create_project/create_project.h
index 2f27cc2..69ed551 100644
--- a/devtools/create_project/create_project.h
+++ b/devtools/create_project/create_project.h
@@ -102,16 +102,17 @@ struct EngineDesc {
 typedef std::list<EngineDesc> EngineDescList;
 
 /**
- * This function parses the project configure file and creates a list
- * of available engines.
+ * This function parses the project directory and creates a list of
+ * available engines.
  *
  * It will also automatically setup the default build state (enabled
- * or disabled) to the state specified in the "configure" file.
+ * or disabled) to the state specified in the individual configure.engine
+ * files.
  *
  * @param srcDir Path to the root of the project source.
  * @return List of available engines.
  */
-EngineDescList parseConfigure(const std::string &srcDir);
+EngineDescList parseEngines(const std::string &srcDir);
 
 /**
  * Checks whether the specified engine is a sub engine. To determine this
@@ -263,6 +264,22 @@ void NORETURN_PRE error(const std::string &message) NORETURN_POST;
 namespace CreateProjectTool {
 
 /**
+ * Structure for describing an FSNode. This is a very minimalistic
+ * description, which includes everything we need.
+ * It only contains the name of the node and whether it is a directory
+ * or not.
+ */
+struct FSNode {
+	FSNode() : name(), isDirectory(false) {}
+	FSNode(const std::string &n, bool iD) : name(n), isDirectory(iD) {}
+
+	std::string name; ///< Name of the file system node
+	bool isDirectory; ///< Whether it is a directory or not
+};
+
+typedef std::list<FSNode> FileList;
+
+/**
  * Gets a proper sequence of \t characters for the given
  * indentation level.
  *
@@ -315,6 +332,15 @@ bool producesObjectFile(const std::string &fileName);
 std::string toString(int num);
 
 /**
+ * Returns a list of all files and directories in the specified
+ * path.
+ *
+ * @param dir Directory which should be listed.
+ * @return List of all children.
+ */
+FileList listDirectory(const std::string &dir);
+
+/**
  * Structure representing a file tree. This contains two
  * members: name and children. "name" holds the name of
  * the node. "children" does contain all the node's children.
@@ -474,6 +500,15 @@ protected:
 	 * @return A new UUID as string.
 	 */
 	std::string createUUID() const;
+
+private:
+	/**
+	 * This creates the engines/plugins_table.h file required for building
+	 * ScummVM.
+	 *
+	 * @param setup Description of the desired build.
+	 */
+	void createEnginePluginsTable(const BuildSetup &setup);
 };
 
 } // End of CreateProjectTool namespace


Commit: 100e45e7488e45eec46a937aa841da1372f4956d
    https://github.com/scummvm/scummvm/commit/100e45e7488e45eec46a937aa841da1372f4956d
Author: Johannes Schickel (lordhoto at scummvm.org)
Date: 2013-11-23T16:48:01-08:00

Commit Message:
BUILD: Add engines/plugins_table.h to git in the ideprojects target.

Changed paths:
    ports.mk



diff --git a/ports.mk b/ports.mk
index f9d0757..9b54b35 100644
--- a/ports.mk
+++ b/ports.mk
@@ -318,15 +318,15 @@ else ifeq "$(CUR_BRANCH)" ""
 	$(error You must be on a release branch) 
 endif
 	@echo Creating Code::Blocks project files...
-	@cd $(srcdir)/dists/codeblocks && ../../devtools/create_project/create_project ../.. --codeblocks >/dev/null && git add -f *.workspace *.cbp
+	@cd $(srcdir)/dists/codeblocks && ../../devtools/create_project/create_project ../.. --codeblocks >/dev/null && git add -f engines/plugins_table.h *.workspace *.cbp
 	@echo Creating MSVC8 project files...
-	@cd $(srcdir)/dists/msvc8 && ../../devtools/create_project/create_project ../.. --msvc --msvc-version 8 >/dev/null && git add -f *.sln *.vcproj *.vsprops
+	@cd $(srcdir)/dists/msvc8 && ../../devtools/create_project/create_project ../.. --msvc --msvc-version 8 >/dev/null && git add -f engines/plugins_table.h *.sln *.vcproj *.vsprops
 	@echo Creating MSVC9 project files...
-	@cd $(srcdir)/dists/msvc9 && ../../devtools/create_project/create_project ../.. --msvc --msvc-version 9 >/dev/null && git add -f *.sln *.vcproj *.vsprops
+	@cd $(srcdir)/dists/msvc9 && ../../devtools/create_project/create_project ../.. --msvc --msvc-version 9 >/dev/null && git add -f engines/plugins_table.h *.sln *.vcproj *.vsprops
 	@echo Creating MSVC10 project files...
-	@cd $(srcdir)/dists/msvc10 && ../../devtools/create_project/create_project ../.. --msvc --msvc-version 10 >/dev/null && git add -f *.sln *.vcxproj *.vcxproj.filters *.props
+	@cd $(srcdir)/dists/msvc10 && ../../devtools/create_project/create_project ../.. --msvc --msvc-version 10 >/dev/null && git add -f engines/plugins_table.h *.sln *.vcxproj *.vcxproj.filters *.props
 	@echo Creating MSVC11 project files...
-	@cd $(srcdir)/dists/msvc11 && ../../devtools/create_project/create_project ../.. --msvc --msvc-version 11 >/dev/null && git add -f *.sln *.vcxproj *.vcxproj.filters *.props
+	@cd $(srcdir)/dists/msvc11 && ../../devtools/create_project/create_project ../.. --msvc --msvc-version 11 >/dev/null && git add -f engines/plugins_table.h *.sln *.vcxproj *.vcxproj.filters *.props
 	@echo
 	@echo All is done.
 	@echo Now run


Commit: 9c025523587410371d5b2e9e4d9643e02f33b5e2
    https://github.com/scummvm/scummvm/commit/9c025523587410371d5b2e9e4d9643e02f33b5e2
Author: D G Turner (digitall at scummvm.org)
Date: 2013-11-23T16:48:01-08:00

Commit Message:
BUILD: Partial solution for parallel make issue.

This is due to the multiple outputs produced by the configure rule,
which cause multiple invocations of configure when make is run in
parallel. Various solutions are detailed in the Multiple-Outputs
section of the GNU automake manual which apply generally to makefiles.

This solution is a simpler one, but should solve the problem, though it
can fail on "mutilated" trees ie. where some of the configure outputs
are present, but not all... but this situation is not common, tends to
be due to an error in configure and should be recoverable by a
"make clean && ./configure" call.

Changed paths:
    Makefile



diff --git a/Makefile b/Makefile
index 45f50f9..88b60ca 100644
--- a/Makefile
+++ b/Makefile
@@ -83,7 +83,7 @@ include $(srcdir)/Makefile.common
 
 # check if configure has been run or has been changed since last run
 ENGINE_SUBDIRS_CONFIGURE := $(wildcard $(srcdir)/engines/*/configure.engine)
-config.h config.mk engines/plugins_table.h engines/engines.mk: $(srcdir)/configure $(ENGINE_SUBDIRS_CONFIGURE)
+config.h: $(srcdir)/configure $(ENGINE_SUBDIRS_CONFIGURE)
 ifeq "$(findstring config.mk,$(MAKEFILE_LIST))" "config.mk"
 	@echo "Running $(srcdir)/configure with the last specified parameters"
 	@sleep 2
@@ -95,6 +95,14 @@ else
 	$(error You need to run $(srcdir)/configure before you can run make. Check $(srcdir)/configure --help for a list of parameters)
 endif
 
+config.mk engines/plugins_table.h engines/engines.mk: config.h
+	@if test -f $@; then \
+		touch $@; \
+	else \
+		rm -f config.h; \
+		$(MAKE) config.h; \
+	fi
+
 ifneq ($(origin port_mk), undefined)
 include $(srcdir)/$(port_mk)
 endif


Commit: 19a20ad71fb8b57504f54786b39ba481dd1400b0
    https://github.com/scummvm/scummvm/commit/19a20ad71fb8b57504f54786b39ba481dd1400b0
Author: D G Turner (digitall at scummvm.org)
Date: 2013-11-23T16:48:01-08:00

Commit Message:
BUILD: Create engines/ dir if necessary, to fix out-of-tree builds

Changed paths:
    configure



diff --git a/configure b/configure
index bf8649a..e474490 100755
--- a/configure
+++ b/configure
@@ -4383,6 +4383,10 @@ EOF
 
 fi
 
+# Ensure engines folder exists prior to trying to generate
+# files into it (used for out-of-tree-builds)
+mkdir -p engines
+
 echo "Creating engines/engines.mk"
 cat > engines/engines.mk << EOF
 # This file is automatically generated by configure


Commit: c00ab00f250205dc76890965562f5b661055826a
    https://github.com/scummvm/scummvm/commit/c00ab00f250205dc76890965562f5b661055826a
Author: Johannes Schickel (lordhoto at scummvm.org)
Date: 2013-11-23T16:48:01-08:00

Commit Message:
DEVTOOLS: Factor out function to create directories in create_project.

Changed paths:
    devtools/create_project/create_project.cpp
    devtools/create_project/create_project.h
    devtools/create_project/xcode.cpp



diff --git a/devtools/create_project/create_project.cpp b/devtools/create_project/create_project.cpp
index ad3160d..026cbe0 100644
--- a/devtools/create_project/create_project.cpp
+++ b/devtools/create_project/create_project.cpp
@@ -59,6 +59,7 @@
 #include <sys/param.h>
 #include <sys/stat.h>
 #include <dirent.h>
+#include <errno.h>
 #endif
 
 namespace {
@@ -1121,6 +1122,32 @@ FileList listDirectory(const std::string &dir) {
 	return result;
 }
 
+void createDirectory(const std::string &dir) {
+#if defined(_WIN32) || defined(WIN32)
+	if (!CreateDirectory(dir.c_str(), NULL)) {
+		if (GetLastError() != ERROR_ALREADY_EXISTS) {
+			error("Could not create folder \"" + dir + "\"");
+		}
+	}
+#else
+	if (mkdir(dir.c_str(), 0777) == -1) {
+		if (errno == EEXIST) {
+			// Try to open as a folder (might be a file / symbolic link)
+			DIR *dirp = opendir(dir.c_str());
+			if (dirp == NULL) {
+				error("Could not create folder \"" + dir + "\"");
+			} else {
+				// The folder exists, just close the stream and return
+				closedir(dirp);
+			}
+		} else {
+			error("Could not create folder \"" + dir + "\"");
+		}
+	}
+#endif
+
+}
+
 /**
  * Scans the specified directory against files, which should be included
  * in the project files. It will not include files present in the exclude list.
diff --git a/devtools/create_project/create_project.h b/devtools/create_project/create_project.h
index 69ed551..459342a 100644
--- a/devtools/create_project/create_project.h
+++ b/devtools/create_project/create_project.h
@@ -341,6 +341,13 @@ std::string toString(int num);
 FileList listDirectory(const std::string &dir);
 
 /**
+ * Create a directory at the given path.
+ *
+ * @param dir The path to create.
+ */
+void createDirectory(const std::string &dir);
+
+/**
  * Structure representing a file tree. This contains two
  * members: name and children. "name" holds the name of
  * the node. "children" does contain all the node's children.
diff --git a/devtools/create_project/xcode.cpp b/devtools/create_project/xcode.cpp
index a9b8e7a..d95bf3e 100644
--- a/devtools/create_project/xcode.cpp
+++ b/devtools/create_project/xcode.cpp
@@ -26,15 +26,6 @@
 #include <fstream>
 #include <algorithm>
 
-#if defined(_WIN32) || defined(WIN32)
-#include <windows.h>
-#else
-#include <sys/param.h>
-#include <sys/stat.h>
-#include <dirent.h>
-#include <errno.h>
-#endif
-
 namespace CreateProjectTool {
 
 #define DEBUG_XCODE_HASH 0
@@ -88,27 +79,7 @@ XCodeProvider::XCodeProvider(StringList &global_warnings, std::map<std::string,
 void XCodeProvider::createWorkspace(const BuildSetup &setup) {
 	// Create project folder
 	std::string workspace = setup.outputDir + '/' + PROJECT_NAME ".xcodeproj";
-
-#if defined(_WIN32) || defined(WIN32)
-	if (!CreateDirectory(workspace.c_str(), NULL))
-		if (GetLastError() != ERROR_ALREADY_EXISTS)
-			error("Could not create folder \"" + setup.outputDir + '/' + PROJECT_NAME ".xcodeproj\"");
-#else
-	if (mkdir(workspace.c_str(), 0777) == -1) {
-		if (errno == EEXIST) {
-			// Try to open as a folder (might be a file / symbolic link)
-			DIR *dirp = opendir(workspace.c_str());
-			if (dirp == NULL) {
-				error("Could not create folder \"" + setup.outputDir + '/' + PROJECT_NAME ".xcodeproj\"");
-			} else {
-				// The folder exists, just close the stream and return
-				closedir(dirp);
-			}
-		} else {
-			error("Could not create folder \"" + setup.outputDir + '/' + PROJECT_NAME ".xcodeproj\"");
-		}
-	}
-#endif
+	createDirectory(workspace);
 
 	// Setup global objects
 	setupDefines(setup);


Commit: 8b3fc996a16dccccb2de01c75d8eff65c89a969f
    https://github.com/scummvm/scummvm/commit/8b3fc996a16dccccb2de01c75d8eff65c89a969f
Author: Johannes Schickel (lordhoto at scummvm.org)
Date: 2013-11-23T16:48:02-08:00

Commit Message:
DEVTOOLS: Adapt create_project to create engines/ dir if necessary

Changed paths:
    devtools/create_project/create_project.cpp



diff --git a/devtools/create_project/create_project.cpp b/devtools/create_project/create_project.cpp
index 026cbe0..3eba36e 100644
--- a/devtools/create_project/create_project.cpp
+++ b/devtools/create_project/create_project.cpp
@@ -1629,6 +1629,10 @@ void ProjectProvider::createModuleList(const std::string &moduleDir, const Strin
 }
 
 void ProjectProvider::createEnginePluginsTable(const BuildSetup &setup) {
+	// First we need to create the "engines" directory.
+	createDirectory(setup.outputDir + "/engines");
+
+	// Then, we can generate the actual "plugins_table.h" file.
 	const std::string enginePluginsTableFile = setup.outputDir + "/engines/plugins_table.h";
 	std::ofstream enginePluginsTable(enginePluginsTableFile.c_str());
 	if (!enginePluginsTable) {


Commit: ffce805fb2b116ef1d4f03540158d42b3fcd5e80
    https://github.com/scummvm/scummvm/commit/ffce805fb2b116ef1d4f03540158d42b3fcd5e80
Author: D G Turner (digitall at scummvm.org)
Date: 2013-11-23T16:48:02-08:00

Commit Message:
BUILD: Add code to maintain ordering of engines in generated files.

This is mainly "cosmetic" to keep the SCUMM engine and subengines at
the top of the various files, but probably a good idea to prevent any
subtle regressions associated with changing the order.

Changed paths:
    configure



diff --git a/configure b/configure
index e474490..d454591 100755
--- a/configure
+++ b/configure
@@ -4199,8 +4199,18 @@ for engine in $_engines; do
 	fi
 done
 
-# Prepare the information to be shown
+# Sort engines to place our headline engine at start...
+# No technical reason, just historical convention
+headline_engine=scumm
+_sorted_engines="${headline_engine}"
 for engine in $_engines; do
+	if test "${engine}" != "${headline_engine}" ; then
+		_sorted_engines="${_sorted_engines} ${engine}"
+	fi
+done
+
+# Prepare the information to be shown
+for engine in $_sorted_engines; do
 	if test "`get_engine_sub $engine`" = "no" ; then
 		# It's a main engine
 		prepare_engine_build_strings $engine
@@ -4394,7 +4404,7 @@ cat > engines/engines.mk << EOF
 # This file is being included by "Makefile.common"
 EOF
 
-for engine in $_engines; do
+for engine in $_sorted_engines; do
 	j=`echo $engine | tr '[:lower:]' '[:upper:]'`
 	if test "`get_engine_sub $engine`" = "no" ; then
 		# main engine
@@ -4428,7 +4438,7 @@ cat > engines/plugins_table.h << EOF
 // This file is being included by "base/plugins.cpp"
 EOF
 
-for engine in $_engines; do
+for engine in $_sorted_engines; do
 	if test "`get_engine_sub $engine`" = "no" ; then
 		j=`echo $engine | tr '[:lower:]' '[:upper:]'`
 		cat >> engines/plugins_table.h << EOF


Commit: 80136c1e51902d4c63264730e26a7b4aff35e829
    https://github.com/scummvm/scummvm/commit/80136c1e51902d4c63264730e26a7b4aff35e829
Author: Johannes Schickel (lordhoto at scummvm.org)
Date: 2013-11-23T16:48:02-08:00

Commit Message:
DEVTOOLS: Make create_project sort SCUMM as first engine.

This makes create_project output consistent with configure output again.

Changed paths:
    devtools/create_project/config.h
    devtools/create_project/create_project.cpp



diff --git a/devtools/create_project/config.h b/devtools/create_project/config.h
index 1a66edf..9d4b101 100644
--- a/devtools/create_project/config.h
+++ b/devtools/create_project/config.h
@@ -27,6 +27,7 @@
 #define PROJECT_NAME "scummvm"           // Used for folders, icons, resources and project/solution name
 #define LIBS_DEFINE "SCUMMVM_LIBS"       // Name of the include environment variable
 #define REVISION_DEFINE "SCUMMVM_INTERNAL_REVISION"
+#define FIRST_ENGINE "scumm"             // Name of the engine which should be sorted as first element
 
 #define ENABLE_LANGUAGE_EXTENSIONS ""    // Comma separated list of projects that need language extensions
 #define DISABLE_EDIT_AND_CONTINUE "tinsel,tony,scummvm"     // Comma separated list of projects that need Edit&Continue to be disabled for co-routine support (the main project is automatically added)
diff --git a/devtools/create_project/create_project.cpp b/devtools/create_project/create_project.cpp
index 3eba36e..16b8e1d 100644
--- a/devtools/create_project/create_project.cpp
+++ b/devtools/create_project/create_project.cpp
@@ -674,6 +674,19 @@ EngineDescList parseEngineConfigure(const std::string &engineDir);
  *         the name of the second operand. "false" otherwise.
  */
 bool compareFSNode(const CreateProjectTool::FSNode &left, const CreateProjectTool::FSNode &right);
+
+#ifdef FIRST_ENGINE
+/**
+ * Compares two FSNode entries in a strict-weak fashion based on engine name
+ * order.
+ *
+ * @param left  The first operand.
+ * @param right The second operand.
+ * @return "true" when the name of the left operand is strictly smaller than
+ *         the name of the second operand. "false" otherwise.
+ */
+bool compareEngineNames(const CreateProjectTool::FSNode &left, const CreateProjectTool::FSNode &right);
+#endif
 } // End of anonymous namespace
 
 EngineDescList parseEngines(const std::string &srcDir) {
@@ -684,9 +697,15 @@ EngineDescList parseEngines(const std::string &srcDir) {
 
 	FileList engineFiles = listDirectory(srcDir + "/engines/");
 
-	// Sort file list alphabetically this allows for a nicer order in
-	// --list-engines output, for example.
+#ifdef FIRST_ENGINE
+	// In case we want to sort an engine to the front of the list we will
+	// use some manual sorting predicate which assures that.
+	engineFiles.sort(&compareEngineNames);
+#else
+	// Otherwise, we simply sort the file list alphabetically this allows
+	// for a nicer order in --list-engines output, for example.
 	engineFiles.sort(&compareFSNode);
+#endif
 
 	for (FileList::const_iterator i = engineFiles.begin(), end = engineFiles.end(); i != end; ++i) {
 		// Each engine requires its own sub directory thus we will skip all
@@ -833,6 +852,18 @@ EngineDescList parseEngineConfigure(const std::string &engineDir) {
 bool compareFSNode(const CreateProjectTool::FSNode &left, const CreateProjectTool::FSNode &right) {
 	return left.name < right.name;
 }
+
+#ifdef FIRST_ENGINE
+bool compareEngineNames(const CreateProjectTool::FSNode &left, const CreateProjectTool::FSNode &right) {
+	if (left.name == FIRST_ENGINE) {
+		return right.name != FIRST_ENGINE;
+	} else if (right.name == FIRST_ENGINE) {
+		return false;
+	} else {
+		return compareFSNode(left, right);
+	}
+}
+#endif
 } // End of anonymous namespace
 
 TokenList tokenize(const std::string &input, char separator) {


Commit: 6b0f1118de6d0f6e6b29dc8778845bf58926c9ad
    https://github.com/scummvm/scummvm/commit/6b0f1118de6d0f6e6b29dc8778845bf58926c9ad
Author: Johannes Schickel (lordhoto at scummvm.org)
Date: 2013-11-24T17:36:25-08:00

Commit Message:
DEVTOOLS: Add project file directory to include path in generated project files.

Changed paths:
    devtools/create_project/codeblocks.cpp
    devtools/create_project/msbuild.cpp
    devtools/create_project/visualstudio.cpp



diff --git a/devtools/create_project/codeblocks.cpp b/devtools/create_project/codeblocks.cpp
index ec003df..442a2b0 100644
--- a/devtools/create_project/codeblocks.cpp
+++ b/devtools/create_project/codeblocks.cpp
@@ -120,6 +120,7 @@ void CodeBlocksProvider::createProjectFile(const std::string &name, const std::s
 		           "\t\t\t\t\t<Add directory=\"..\\..\\engines\" />\n"
 		           "\t\t\t\t\t<Add directory=\"..\\..\\common\" />\n"
 		           "\t\t\t\t\t<Add directory=\"..\\..\" />\n"
+		           "\t\t\t\t\t<Add directory=\".\\\" />\n"
 		           "\t\t\t\t</Compiler>\n";
 
 		//////////////////////////////////////////////////////////////////////////
diff --git a/devtools/create_project/msbuild.cpp b/devtools/create_project/msbuild.cpp
index 0d68b2e..07ae20e 100644
--- a/devtools/create_project/msbuild.cpp
+++ b/devtools/create_project/msbuild.cpp
@@ -360,7 +360,7 @@ void MSBuildProvider::outputGlobalPropFile(const BuildSetup &setup, std::ofstrea
 	              "\t\t<ClCompile>\n"
 	              "\t\t\t<DisableLanguageExtensions>true</DisableLanguageExtensions>\n"
 	              "\t\t\t<DisableSpecificWarnings>" << warnings << ";%(DisableSpecificWarnings)</DisableSpecificWarnings>\n"
-	              "\t\t\t<AdditionalIncludeDirectories>$(" << LIBS_DEFINE << ")\\include;" << prefix << ";" << prefix << "\\engines;" << (setup.tests ? prefix + "\\test\\cxxtest;" : "") << "$(TargetDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>\n"
+	              "\t\t\t<AdditionalIncludeDirectories>$(" << LIBS_DEFINE << ")\\include;.\\;" << prefix << ";" << prefix << "\\engines;" << (setup.tests ? prefix + "\\test\\cxxtest;" : "") << "$(TargetDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>\n"
 	              "\t\t\t<PreprocessorDefinitions>" << definesList << "%(PreprocessorDefinitions)</PreprocessorDefinitions>\n"
 	              "\t\t\t<ExceptionHandling>" << ((setup.devTools || setup.tests) ? "Sync" : "") << "</ExceptionHandling>\n";
 
diff --git a/devtools/create_project/visualstudio.cpp b/devtools/create_project/visualstudio.cpp
index 438e077..84bc674 100644
--- a/devtools/create_project/visualstudio.cpp
+++ b/devtools/create_project/visualstudio.cpp
@@ -232,7 +232,7 @@ void VisualStudioProvider::outputGlobalPropFile(const BuildSetup &setup, std::of
 	              "\t\tName=\"VCCLCompilerTool\"\n"
 	              "\t\tDisableLanguageExtensions=\"" << (setup.devTools ? "false" : "true") << "\"\n"
 	              "\t\tDisableSpecificWarnings=\"" << warnings << "\"\n"
-	              "\t\tAdditionalIncludeDirectories=\"" << prefix << ";" << prefix << "\\engines;$(" << LIBS_DEFINE << ")\\include;" << (setup.tests ? prefix + "\\test\\cxxtest;" : "") << "$(TargetDir)\"\n"
+	              "\t\tAdditionalIncludeDirectories=\".\\;" << prefix << ";" << prefix << "\\engines;$(" << LIBS_DEFINE << ")\\include;" << (setup.tests ? prefix + "\\test\\cxxtest;" : "") << "$(TargetDir)\"\n"
 	              "\t\tPreprocessorDefinitions=\"" << definesList << "\"\n"
 	              "\t\tExceptionHandling=\"" << ((setup.devTools || setup.tests) ? "1" : "0") << "\"\n";
 


Commit: 0e017f007a8a3db8c8d8320f76cbfd423e662e07
    https://github.com/scummvm/scummvm/commit/0e017f007a8a3db8c8d8320f76cbfd423e662e07
Author: Johannes Schickel (lordhoto at gmail.com)
Date: 2013-11-26T02:27:11-08:00

Commit Message:
Merge pull request #375 from digitall/engineAutoPlug

RFC: Pluggable Engines #2 (No Python, just evolution of current configure shell and make code)

Changed paths:
  A engines/agi/configure.engine
  A engines/agos/configure.engine
  A engines/avalanche/configure.engine
  A engines/cge/configure.engine
  A engines/cine/configure.engine
  A engines/composer/configure.engine
  A engines/cruise/configure.engine
  A engines/draci/configure.engine
  A engines/drascula/configure.engine
  A engines/dreamweb/configure.engine
  A engines/fullpipe/configure.engine
  A engines/gob/configure.engine
  A engines/groovie/configure.engine
  A engines/hopkins/configure.engine
  A engines/hugo/configure.engine
  A engines/kyra/configure.engine
  A engines/lastexpress/configure.engine
  A engines/lure/configure.engine
  A engines/made/configure.engine
  A engines/mohawk/configure.engine
  A engines/mortevielle/configure.engine
  A engines/neverhood/configure.engine
  A engines/parallaction/configure.engine
  A engines/pegasus/configure.engine
  A engines/queen/configure.engine
  A engines/saga/configure.engine
  A engines/sci/configure.engine
  A engines/scumm/configure.engine
  A engines/sky/configure.engine
  A engines/sword1/configure.engine
  A engines/sword2/configure.engine
  A engines/sword25/configure.engine
  A engines/teenagent/configure.engine
  A engines/testbed/configure.engine
  A engines/tinsel/configure.engine
  A engines/toltecs/configure.engine
  A engines/tony/configure.engine
  A engines/toon/configure.engine
  A engines/touche/configure.engine
  A engines/tsage/configure.engine
  A engines/tucker/configure.engine
  A engines/wintermute/configure.engine
  A engines/zvision/configure.engine
  R engines/configure.engines
  R engines/engines.mk
  R engines/plugins_table.h
    .gitignore
    Makefile
    Makefile.common
    configure
    devtools/create_project/codeblocks.cpp
    devtools/create_project/config.h
    devtools/create_project/create_project.cpp
    devtools/create_project/create_project.h
    devtools/create_project/msbuild.cpp
    devtools/create_project/visualstudio.cpp
    devtools/create_project/xcode.cpp
    ports.mk









More information about the Scummvm-git-logs mailing list