aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile.common6
-rw-r--r--engines/agi/engine.mk4
-rw-r--r--engines/agos/engine.mk8
-rw-r--r--engines/avalanche/engine.mk4
-rw-r--r--engines/cge/engine.mk4
-rw-r--r--engines/cine/engine.mk4
-rw-r--r--engines/composer/engine.mk4
-rw-r--r--engines/cruise/engine.mk4
-rw-r--r--engines/draci/engine.mk4
-rw-r--r--engines/drascula/engine.mk4
-rw-r--r--engines/dreamweb/engine.mk4
-rw-r--r--engines/engines.mk263
-rw-r--r--engines/fullpipe/engine.mk4
-rw-r--r--engines/gob/engine.mk4
-rw-r--r--engines/groovie/engine.mk8
-rw-r--r--engines/hopkins/engine.mk4
-rw-r--r--engines/hugo/engine.mk4
-rw-r--r--engines/kyra/engine.mk12
-rw-r--r--engines/lastexpress/engine.mk4
-rw-r--r--engines/lure/engine.mk4
-rw-r--r--engines/made/engine.mk4
-rw-r--r--engines/mohawk/engine.mk16
-rw-r--r--engines/mortevielle/engine.mk4
-rw-r--r--engines/neverhood/engine.mk4
-rw-r--r--engines/parallaction/engine.mk4
-rw-r--r--engines/pegasus/engine.mk4
-rw-r--r--engines/queen/engine.mk4
-rw-r--r--engines/saga/engine.mk12
-rw-r--r--engines/sci/engine.mk8
-rw-r--r--engines/scumm/engine.mk12
-rw-r--r--engines/sky/engine.mk4
-rw-r--r--engines/sword1/engine.mk4
-rw-r--r--engines/sword2/engine.mk4
-rw-r--r--engines/sword25/engine.mk4
-rw-r--r--engines/teenagent/engine.mk4
-rw-r--r--engines/testbed/engine.mk4
-rw-r--r--engines/tinsel/engine.mk4
-rw-r--r--engines/toltecs/engine.mk4
-rw-r--r--engines/tony/engine.mk4
-rw-r--r--engines/toon/engine.mk4
-rw-r--r--engines/touche/engine.mk4
-rw-r--r--engines/tsage/engine.mk4
-rw-r--r--engines/tucker/engine.mk4
-rw-r--r--engines/wintermute/engine.mk4
-rw-r--r--engines/zvision/engine.mk4
45 files changed, 224 insertions, 265 deletions
diff --git a/Makefile.common b/Makefile.common
index 02c3408684..41a3245b76 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 0000000000..18963fd4a4
--- /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 0000000000..ba60a78844
--- /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 0000000000..17356ee376
--- /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 0000000000..c71f4e0df2
--- /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 0000000000..a32c319d3c
--- /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 0000000000..b444021013
--- /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 0000000000..ac37c61834
--- /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 0000000000..81ccc3f70f
--- /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 0000000000..ca4f6c9883
--- /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 0000000000..088fcca535
--- /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 cfde77321d..0000000000
--- 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 0000000000..7aeec541f1
--- /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 0000000000..c78e7ddbf1
--- /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 0000000000..a209860e84
--- /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 0000000000..ac2281c0be
--- /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 0000000000..a6ca531dd0
--- /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 0000000000..a2bfce3038
--- /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 0000000000..6e0ba3bf25
--- /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 0000000000..62be295b28
--- /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 0000000000..8fd832cbb5
--- /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 0000000000..e9474b5534
--- /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 0000000000..4232dece3d
--- /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 0000000000..52b032a5d8
--- /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 0000000000..465b6fc813
--- /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 0000000000..60bba59e65
--- /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 0000000000..05f3dcad91
--- /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 0000000000..a6e855bafd
--- /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 0000000000..7f26a19833
--- /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 0000000000..640dfb51b4
--- /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 0000000000..182e6082a2
--- /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 0000000000..39f6afb4fb
--- /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 0000000000..5f05112180
--- /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 0000000000..32a906c5cd
--- /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 0000000000..82004eb489
--- /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 0000000000..b19db6ee9d
--- /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 0000000000..f3df46bc34
--- /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 0000000000..38bf6c04b8
--- /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 0000000000..605f2e6cd2
--- /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 0000000000..ec8b66f122
--- /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 0000000000..1629a82b2c
--- /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 0000000000..d734665560
--- /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 0000000000..6342af048e
--- /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 0000000000..145d2f76b8
--- /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 0000000000..be76a4d67d
--- /dev/null
+++ b/engines/zvision/engine.mk
@@ -0,0 +1,4 @@
+ifdef ENABLE_ZVISION
+DEFINES += -DENABLE_ZVISION=$(ENABLE_ZVISION)
+MODULES += engines/zvision
+endif