Makefile: Set config options from mode-specific make variables.
[exim-config] / Makefile
index 844b31a..49a1179 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -60,7 +60,7 @@ MODES                 += satellite
 OPTIONS_satellite       = satellite.m4 sat-rewrite.m4
 
 MODES                  += srv
-HOOKS_srv               = nosysdomain.m4
+CONF_srv                = sysdomains=
 OPTIONS_srv             = exchange.m4 spam.m4 vhost.m4 sat-rewrite.m4
 
 MODES                  += hub
@@ -81,7 +81,7 @@ HOST_MODES            += $(foreach m, $(MODES), \
 CONFIGS                         = $(foreach m, $(MODES), exim4-$m.conf)
 TARGETS                        += $(CONFIGS)
 $(CONFIGS): exim4-%.conf: $(EARLY) $$(HOOKS_$$*) $(MAIN) $$(OPTIONS_$$*)
-       $(V_GEN)m4 -P -DMODE=$* $^ >$@.new
+       $(V_GEN)m4 -P -DMODE=$* $(CONF_$*:%=-DCONF_%) $^ >$@.new
        $(V_AT)$(CHECK_$*)exim4 -C$$(pwd)/$@.new -bV >/dev/null
        $(V_AT)mv $@.new $@