aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--build/bootstrap.make31
-rw-r--r--examples/cxx/parser/generated/makefile2
-rw-r--r--examples/cxx/parser/hello/makefile2
-rw-r--r--examples/cxx/parser/library/makefile2
-rw-r--r--examples/cxx/parser/mixed/makefile2
-rw-r--r--examples/cxx/parser/mixin/makefile2
-rw-r--r--examples/cxx/parser/multiroot/makefile2
-rw-r--r--examples/cxx/parser/performance/makefile2
-rw-r--r--examples/cxx/parser/polymorphism/makefile2
-rw-r--r--examples/cxx/parser/polyroot/makefile2
-rw-r--r--examples/cxx/parser/wildcard/makefile2
-rw-r--r--examples/cxx/tree/binary/boost/makefile2
-rw-r--r--examples/cxx/tree/binary/cdr/makefile2
-rw-r--r--examples/cxx/tree/binary/xdr/makefile2
-rw-r--r--examples/cxx/tree/caching/makefile2
-rw-r--r--examples/cxx/tree/compression/makefile2
-rw-r--r--examples/cxx/tree/custom/calendar/makefile2
-rw-r--r--examples/cxx/tree/custom/comments/makefile2
-rw-r--r--examples/cxx/tree/custom/contacts/makefile2
-rw-r--r--examples/cxx/tree/custom/double/makefile2
-rw-r--r--examples/cxx/tree/custom/mixed/makefile2
-rw-r--r--examples/cxx/tree/custom/taxonomy/makefile2
-rw-r--r--examples/cxx/tree/custom/wildcard/makefile2
-rw-r--r--examples/cxx/tree/embedded/makefile2
-rw-r--r--examples/cxx/tree/hello/makefile2
-rw-r--r--examples/cxx/tree/library/makefile2
-rw-r--r--examples/cxx/tree/messaging/makefile2
-rw-r--r--examples/cxx/tree/mixed/makefile2
-rw-r--r--examples/cxx/tree/multiroot/makefile2
-rw-r--r--examples/cxx/tree/performance/makefile2
-rw-r--r--examples/cxx/tree/polymorphism/makefile2
-rw-r--r--examples/cxx/tree/streaming/makefile2
-rw-r--r--examples/cxx/tree/wildcard/makefile2
-rw-r--r--examples/cxx/tree/xpath/makefile2
-rw-r--r--tests/cxx/parser/built-in/makefile2
-rw-r--r--tests/cxx/parser/enumeration/makefile2
-rw-r--r--tests/cxx/parser/generated-impl/makefile2
-rw-r--r--tests/cxx/parser/list/makefile2
-rw-r--r--tests/cxx/parser/name-clash/inheritance/makefile2
-rw-r--r--tests/cxx/parser/polymorphism/recursive/makefile2
-rw-r--r--tests/cxx/parser/polymorphism/same-type/makefile2
-rw-r--r--tests/cxx/parser/recursive/makefile2
-rw-r--r--tests/cxx/parser/test-template/makefile2
-rw-r--r--tests/cxx/parser/union/makefile2
-rw-r--r--tests/cxx/parser/validation/all/makefile2
-rw-r--r--tests/cxx/parser/validation/any/makefile2
-rw-r--r--tests/cxx/parser/validation/attribute/makefile2
-rw-r--r--tests/cxx/parser/validation/built-in/any-type/makefile2
-rw-r--r--tests/cxx/parser/validation/built-in/binary/makefile2
-rw-r--r--tests/cxx/parser/validation/built-in/boolean/makefile2
-rw-r--r--tests/cxx/parser/validation/built-in/byte/makefile2
-rw-r--r--tests/cxx/parser/validation/built-in/date-time/makefile2
-rw-r--r--tests/cxx/parser/validation/built-in/float/makefile2
-rw-r--r--tests/cxx/parser/validation/built-in/int/makefile2
-rw-r--r--tests/cxx/parser/validation/built-in/integer/makefile2
-rw-r--r--tests/cxx/parser/validation/built-in/long/makefile2
-rw-r--r--tests/cxx/parser/validation/built-in/qname/makefile2
-rw-r--r--tests/cxx/parser/validation/built-in/short/makefile2
-rw-r--r--tests/cxx/parser/validation/built-in/string/makefile2
-rw-r--r--tests/cxx/parser/validation/built-in/uri/makefile2
-rw-r--r--tests/cxx/parser/validation/choice/makefile2
-rw-r--r--tests/cxx/parser/validation/restriction/makefile2
-rw-r--r--tests/cxx/parser/validation/sequence/makefile2
-rw-r--r--tests/cxx/tree/binary/cdr/makefile2
-rw-r--r--tests/cxx/tree/binary/polymorphic/makefile2
-rw-r--r--tests/cxx/tree/binary/xdr/makefile2
-rw-r--r--tests/cxx/tree/built-in/makefile3
-rw-r--r--tests/cxx/tree/chameleon/makefile2
-rw-r--r--tests/cxx/tree/comparison/makefile2
-rw-r--r--tests/cxx/tree/compilation/makefile2
-rw-r--r--tests/cxx/tree/complex/ctor/makefile2
-rw-r--r--tests/cxx/tree/containment/makefile2
-rw-r--r--tests/cxx/tree/default/general/makefile2
-rw-r--r--tests/cxx/tree/default/omit/makefile2
-rw-r--r--tests/cxx/tree/detach/makefile2
-rw-r--r--tests/cxx/tree/encoding/char/iso-8859-1/makefile2
-rw-r--r--tests/cxx/tree/encoding/char/lcp/makefile2
-rw-r--r--tests/cxx/tree/encoding/char/utf-8/makefile2
-rw-r--r--tests/cxx/tree/encoding/wchar/makefile2
-rw-r--r--tests/cxx/tree/enumeration/ctor/makefile2
-rw-r--r--tests/cxx/tree/enumeration/inheritance/makefile2
-rw-r--r--tests/cxx/tree/float/makefile2
-rw-r--r--tests/cxx/tree/list/ctor/makefile2
-rw-r--r--tests/cxx/tree/name-clash/inheritance/makefile2
-rw-r--r--tests/cxx/tree/naming/camel/makefile2
-rw-r--r--tests/cxx/tree/naming/java/makefile2
-rw-r--r--tests/cxx/tree/naming/knr/makefile2
-rw-r--r--tests/cxx/tree/polymorphism/comparison/makefile2
-rw-r--r--tests/cxx/tree/polymorphism/ostream/makefile2
-rw-r--r--tests/cxx/tree/polymorphism/same-type/makefile2
-rw-r--r--tests/cxx/tree/prefix/makefile2
-rw-r--r--tests/cxx/tree/test-template/makefile2
-rw-r--r--tests/cxx/tree/types-only/makefile2
-rw-r--r--tests/cxx/tree/union/ctor/makefile2
-rw-r--r--tests/cxx/tree/wildcard/makefile2
95 files changed, 119 insertions, 101 deletions
diff --git a/build/bootstrap.make b/build/bootstrap.make
index 974f915..1a1c160 100644
--- a/build/bootstrap.make
+++ b/build/bootstrap.make
@@ -16,10 +16,17 @@ ifeq ($(patsubst %build/bootstrap.make,,$(lastword $(MAKEFILE_LIST))),)
include $(build)/bootstrap.make
endif
+def_goal := $(.DEFAULT_GOAL)
+
# Configuration
#
$(call include,$(scf_root)/configuration.make)
+# Include C++ configuration. We need to know if we are using the generic
+# C++ compiler in which case we need to compensate for missing dependency
+# auto-generation (see below).
+#
+$(call include,$(bld_root)/cxx/configuration.make)
# Aliases
#
@@ -43,10 +50,6 @@ dist-win: $(out_base)/.dist-win
clean: $(out_base)/.clean
cleandoc: $(out_base)/.cleandoc
-ifneq ($(filter $(.DEFAULT_GOAL),test install dist dist-win clean cleandoc),)
-.DEFAULT_GOAL :=
-endif
-
endif
@@ -58,13 +61,27 @@ $(error dist_prefix is not set)
endif
endif
-
-# Don't include dependency info for certain targets.
+# If we don't have dependency auto-generation then we need to manually
+# make sure that generated files are generated before C++ file are
+# compiler. To do this we make the object files ($2) depend in order-
+# only on generated files ($3).
#
+ifeq ($(cxx_id),generic)
+
+define include-dep
+$(if $2,$(eval $2: | $3))
+endef
+
+else
+
define include-dep
$(call -include,$1)
endef
+endif
+
+# Don't include dependency info for certain targets.
+#
ifneq ($(filter $(MAKECMDGOALS),clean cleandoc disfigure),)
include-dep =
endif
@@ -84,3 +101,5 @@ include-dep =
endif
endif
+
+.DEFAULT_GOAL := $(def_goal)
diff --git a/examples/cxx/parser/generated/makefile b/examples/cxx/parser/generated/makefile
index 4eadfa0..fefa1f8 100644
--- a/examples/cxx/parser/generated/makefile
+++ b/examples/cxx/parser/generated/makefile
@@ -45,7 +45,7 @@ $(gen): xsd_options := --generate-print-impl --generate-test-driver \
--force-overwrite
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/parser/hello/makefile b/examples/cxx/parser/hello/makefile
index 6811083..21ffdc2 100644
--- a/examples/cxx/parser/hello/makefile
+++ b/examples/cxx/parser/hello/makefile
@@ -38,7 +38,7 @@ gen := $(addprefix $(out_base)/,$(genf))
$(gen): xsd := $(out_root)/xsd/xsd
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/parser/library/makefile b/examples/cxx/parser/library/makefile
index d5590b6..4f8082c 100644
--- a/examples/cxx/parser/library/makefile
+++ b/examples/cxx/parser/library/makefile
@@ -39,7 +39,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-inline --type-map $(src_base)/library.map
$(gen): $(out_root)/xsd/xsd $(src_base)/library.map
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/parser/mixed/makefile b/examples/cxx/parser/mixed/makefile
index f616b88..7feca93 100644
--- a/examples/cxx/parser/mixed/makefile
+++ b/examples/cxx/parser/mixed/makefile
@@ -39,7 +39,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --type-map $(src_base)/text.map
$(gen): $(out_root)/xsd/xsd $(src_base)/text.map
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/parser/mixin/makefile b/examples/cxx/parser/mixin/makefile
index 945d28b..b30261d 100644
--- a/examples/cxx/parser/mixin/makefile
+++ b/examples/cxx/parser/mixin/makefile
@@ -39,7 +39,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --type-map $(src_base)/schema.map
$(gen): $(out_root)/xsd/xsd $(src_base)/schema.map
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/parser/multiroot/makefile b/examples/cxx/parser/multiroot/makefile
index 51046cf..016a63b 100644
--- a/examples/cxx/parser/multiroot/makefile
+++ b/examples/cxx/parser/multiroot/makefile
@@ -39,7 +39,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --type-map $(src_base)/protocol.map
$(gen): $(out_root)/xsd/xsd $(src_base)/protocol.map
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/parser/performance/makefile b/examples/cxx/parser/performance/makefile
index d2fa512..e8efd93 100644
--- a/examples/cxx/parser/performance/makefile
+++ b/examples/cxx/parser/performance/makefile
@@ -39,7 +39,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-inline
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/parser/polymorphism/makefile b/examples/cxx/parser/polymorphism/makefile
index 36805f3..17fc38a 100644
--- a/examples/cxx/parser/polymorphism/makefile
+++ b/examples/cxx/parser/polymorphism/makefile
@@ -39,7 +39,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-polymorphic
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/parser/polyroot/makefile b/examples/cxx/parser/polyroot/makefile
index 6cb31e7..c0a8020 100644
--- a/examples/cxx/parser/polyroot/makefile
+++ b/examples/cxx/parser/polyroot/makefile
@@ -39,7 +39,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-polymorphic
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/parser/wildcard/makefile b/examples/cxx/parser/wildcard/makefile
index a6ad403..0179361 100644
--- a/examples/cxx/parser/wildcard/makefile
+++ b/examples/cxx/parser/wildcard/makefile
@@ -38,7 +38,7 @@ gen := $(addprefix $(out_base)/,$(genf))
$(gen): xsd := $(out_root)/xsd/xsd
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/binary/boost/makefile b/examples/cxx/tree/binary/boost/makefile
index faaf7d6..2a2c297 100644
--- a/examples/cxx/tree/binary/boost/makefile
+++ b/examples/cxx/tree/binary/boost/makefile
@@ -50,7 +50,7 @@ $(gen): xsd_options := --generate-ostream \
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/binary/cdr/makefile b/examples/cxx/tree/binary/cdr/makefile
index 58045d7..d09b730 100644
--- a/examples/cxx/tree/binary/cdr/makefile
+++ b/examples/cxx/tree/binary/cdr/makefile
@@ -46,7 +46,7 @@ $(gen): xsd_options := --generate-ostream \
--generate-insertion ACE_OutputCDR --generate-extraction ACE_InputCDR
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/binary/xdr/makefile b/examples/cxx/tree/binary/xdr/makefile
index 20469f8..55613a8 100644
--- a/examples/cxx/tree/binary/xdr/makefile
+++ b/examples/cxx/tree/binary/xdr/makefile
@@ -38,7 +38,7 @@ $(gen): xsd_options := --generate-ostream \
--generate-insertion XDR --generate-extraction XDR
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/caching/makefile b/examples/cxx/tree/caching/makefile
index a30effb..eb05222 100644
--- a/examples/cxx/tree/caching/makefile
+++ b/examples/cxx/tree/caching/makefile
@@ -39,7 +39,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options :=
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/compression/makefile b/examples/cxx/tree/compression/makefile
index c5589d4..04c867d 100644
--- a/examples/cxx/tree/compression/makefile
+++ b/examples/cxx/tree/compression/makefile
@@ -44,7 +44,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-ostream --generate-serialization
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/custom/calendar/makefile b/examples/cxx/tree/custom/calendar/makefile
index d28be1c..656ceab 100644
--- a/examples/cxx/tree/custom/calendar/makefile
+++ b/examples/cxx/tree/custom/calendar/makefile
@@ -57,7 +57,7 @@ $(gen): xsd_options := \
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/custom/comments/makefile b/examples/cxx/tree/custom/comments/makefile
index a39719b..4138710 100644
--- a/examples/cxx/tree/custom/comments/makefile
+++ b/examples/cxx/tree/custom/comments/makefile
@@ -52,7 +52,7 @@ $(gen): xsd_options := \
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/custom/contacts/makefile b/examples/cxx/tree/custom/contacts/makefile
index 2cb58fc..c3d45f6 100644
--- a/examples/cxx/tree/custom/contacts/makefile
+++ b/examples/cxx/tree/custom/contacts/makefile
@@ -47,7 +47,7 @@ $(gen): xsd_options := \
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/custom/double/makefile b/examples/cxx/tree/custom/double/makefile
index 9b33821..ee90e7e 100644
--- a/examples/cxx/tree/custom/double/makefile
+++ b/examples/cxx/tree/custom/double/makefile
@@ -47,7 +47,7 @@ $(gen): xsd_options := \
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/custom/mixed/makefile b/examples/cxx/tree/custom/mixed/makefile
index e91c085..f95c1fe 100644
--- a/examples/cxx/tree/custom/mixed/makefile
+++ b/examples/cxx/tree/custom/mixed/makefile
@@ -48,7 +48,7 @@ $(gen): xsd_options := \
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/custom/taxonomy/makefile b/examples/cxx/tree/custom/taxonomy/makefile
index 3771bed..48ba7e8 100644
--- a/examples/cxx/tree/custom/taxonomy/makefile
+++ b/examples/cxx/tree/custom/taxonomy/makefile
@@ -53,7 +53,7 @@ $(gen): xsd_options := \
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/custom/wildcard/makefile b/examples/cxx/tree/custom/wildcard/makefile
index ce78ffd..c90526b 100644
--- a/examples/cxx/tree/custom/wildcard/makefile
+++ b/examples/cxx/tree/custom/wildcard/makefile
@@ -49,7 +49,7 @@ $(gen): xsd_options := \
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/embedded/makefile b/examples/cxx/tree/embedded/makefile
index 4fb586b..ffc9ded 100644
--- a/examples/cxx/tree/embedded/makefile
+++ b/examples/cxx/tree/embedded/makefile
@@ -50,7 +50,7 @@ $(out_base)/%: xsdbin := $(xsdbin)
$(out_base)/%-schema.hxx $(out_base)/%-schema.cxx: $(src_base)/%.xsd $(xsdbin)
$(call message,xsdbin $<,$(xsdbin) --output-dir $(out_base) $<)
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/hello/makefile b/examples/cxx/tree/hello/makefile
index 9334039..a2662a5 100644
--- a/examples/cxx/tree/hello/makefile
+++ b/examples/cxx/tree/hello/makefile
@@ -39,7 +39,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options :=
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/library/makefile b/examples/cxx/tree/library/makefile
index d5681de..d984aaa 100644
--- a/examples/cxx/tree/library/makefile
+++ b/examples/cxx/tree/library/makefile
@@ -40,7 +40,7 @@ $(gen): xsd_options := --generate-inline --generate-ostream \
--generate-serialization
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/messaging/makefile b/examples/cxx/tree/messaging/makefile
index a3705f2..31a67a4 100644
--- a/examples/cxx/tree/messaging/makefile
+++ b/examples/cxx/tree/messaging/makefile
@@ -42,7 +42,7 @@ $(gen): xsd_options := --root-element-all \
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/mixed/makefile b/examples/cxx/tree/mixed/makefile
index 85ea792..9da0d41 100644
--- a/examples/cxx/tree/mixed/makefile
+++ b/examples/cxx/tree/mixed/makefile
@@ -39,7 +39,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options :=
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
diff --git a/examples/cxx/tree/multiroot/makefile b/examples/cxx/tree/multiroot/makefile
index cbb0063..6c0e9ec 100644
--- a/examples/cxx/tree/multiroot/makefile
+++ b/examples/cxx/tree/multiroot/makefile
@@ -39,7 +39,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --root-element-all
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/performance/makefile b/examples/cxx/tree/performance/makefile
index 70fb1ef..d3e29b6 100644
--- a/examples/cxx/tree/performance/makefile
+++ b/examples/cxx/tree/performance/makefile
@@ -39,7 +39,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-inline --generate-serialization
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/polymorphism/makefile b/examples/cxx/tree/polymorphism/makefile
index e6ad998..aadb79e 100644
--- a/examples/cxx/tree/polymorphism/makefile
+++ b/examples/cxx/tree/polymorphism/makefile
@@ -40,7 +40,7 @@ $(gen): xsd_options := --generate-polymorphic --generate-serialization \
--root-element-last
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
diff --git a/examples/cxx/tree/streaming/makefile b/examples/cxx/tree/streaming/makefile
index 3868bc8..9e07aec 100644
--- a/examples/cxx/tree/streaming/makefile
+++ b/examples/cxx/tree/streaming/makefile
@@ -39,7 +39,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-serialization
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/wildcard/makefile b/examples/cxx/tree/wildcard/makefile
index 11b6473..d0c47b7 100644
--- a/examples/cxx/tree/wildcard/makefile
+++ b/examples/cxx/tree/wildcard/makefile
@@ -40,7 +40,7 @@ $(gen): xsd_options := --generate-inline --generate-wildcard \
--generate-serialization --root-element message
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/examples/cxx/tree/xpath/makefile b/examples/cxx/tree/xpath/makefile
index b3164a0..0bf123e 100644
--- a/examples/cxx/tree/xpath/makefile
+++ b/examples/cxx/tree/xpath/makefile
@@ -45,7 +45,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options :=
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/built-in/makefile b/tests/cxx/parser/built-in/makefile
index c661e55..2ad17e9 100644
--- a/tests/cxx/parser/built-in/makefile
+++ b/tests/cxx/parser/built-in/makefile
@@ -34,7 +34,7 @@ gen := $(addprefix $(out_base)/,$(genf))
$(gen): xsd := $(out_root)/xsd/xsd
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/enumeration/makefile b/tests/cxx/parser/enumeration/makefile
index 975bfd6..7d4ab20 100644
--- a/tests/cxx/parser/enumeration/makefile
+++ b/tests/cxx/parser/enumeration/makefile
@@ -35,7 +35,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --type-map $(src_base)/test.map
$(gen): $(out_root)/xsd/xsd $(src_base)/test.map
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/generated-impl/makefile b/tests/cxx/parser/generated-impl/makefile
index bb30c89..acd542f 100644
--- a/tests/cxx/parser/generated-impl/makefile
+++ b/tests/cxx/parser/generated-impl/makefile
@@ -42,7 +42,7 @@ $(gen): xsd_options := --generate-print-impl --generate-test-driver \
--force-overwrite
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/list/makefile b/tests/cxx/parser/list/makefile
index a987d1a..4c149b8 100644
--- a/tests/cxx/parser/list/makefile
+++ b/tests/cxx/parser/list/makefile
@@ -34,7 +34,7 @@ gen := $(addprefix $(out_base)/,$(genf))
$(gen): xsd := $(out_root)/xsd/xsd
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/name-clash/inheritance/makefile b/tests/cxx/parser/name-clash/inheritance/makefile
index 30a3397..641f993 100644
--- a/tests/cxx/parser/name-clash/inheritance/makefile
+++ b/tests/cxx/parser/name-clash/inheritance/makefile
@@ -35,7 +35,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-validation
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/polymorphism/recursive/makefile b/tests/cxx/parser/polymorphism/recursive/makefile
index 4ae706e..595406d 100644
--- a/tests/cxx/parser/polymorphism/recursive/makefile
+++ b/tests/cxx/parser/polymorphism/recursive/makefile
@@ -35,7 +35,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-polymorphic
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/polymorphism/same-type/makefile b/tests/cxx/parser/polymorphism/same-type/makefile
index ed131df..7f1ab04 100644
--- a/tests/cxx/parser/polymorphism/same-type/makefile
+++ b/tests/cxx/parser/polymorphism/same-type/makefile
@@ -35,7 +35,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-polymorphic
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/recursive/makefile b/tests/cxx/parser/recursive/makefile
index a0ad25a..21b80c2 100644
--- a/tests/cxx/parser/recursive/makefile
+++ b/tests/cxx/parser/recursive/makefile
@@ -35,7 +35,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-validation
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/test-template/makefile b/tests/cxx/parser/test-template/makefile
index fa552f1..0615b3e 100644
--- a/tests/cxx/parser/test-template/makefile
+++ b/tests/cxx/parser/test-template/makefile
@@ -34,7 +34,7 @@ gen := $(addprefix $(out_base)/,$(genf))
$(gen): xsd := $(out_root)/xsd/xsd
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/union/makefile b/tests/cxx/parser/union/makefile
index 8fcfc14..fad1009 100644
--- a/tests/cxx/parser/union/makefile
+++ b/tests/cxx/parser/union/makefile
@@ -34,7 +34,7 @@ gen := $(addprefix $(out_base)/,$(genf))
$(gen): xsd := $(out_root)/xsd/xsd
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/validation/all/makefile b/tests/cxx/parser/validation/all/makefile
index f14758f..d772718 100644
--- a/tests/cxx/parser/validation/all/makefile
+++ b/tests/cxx/parser/validation/all/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-validation
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
diff --git a/tests/cxx/parser/validation/any/makefile b/tests/cxx/parser/validation/any/makefile
index f0c603b..6e38eaa 100644
--- a/tests/cxx/parser/validation/any/makefile
+++ b/tests/cxx/parser/validation/any/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-validation
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
diff --git a/tests/cxx/parser/validation/attribute/makefile b/tests/cxx/parser/validation/attribute/makefile
index 18581df..d3571ef 100644
--- a/tests/cxx/parser/validation/attribute/makefile
+++ b/tests/cxx/parser/validation/attribute/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-validation
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
diff --git a/tests/cxx/parser/validation/built-in/any-type/makefile b/tests/cxx/parser/validation/built-in/any-type/makefile
index 478c522..4d3ff6e 100644
--- a/tests/cxx/parser/validation/built-in/any-type/makefile
+++ b/tests/cxx/parser/validation/built-in/any-type/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-validation
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
diff --git a/tests/cxx/parser/validation/built-in/binary/makefile b/tests/cxx/parser/validation/built-in/binary/makefile
index 7781caa..8b2d09e 100644
--- a/tests/cxx/parser/validation/built-in/binary/makefile
+++ b/tests/cxx/parser/validation/built-in/binary/makefile
@@ -28,7 +28,7 @@ $(driver): $(obj) $(xerces_c.l)
$(obj) $(dep): cpp_options := -I$(src_root)/libxsd
$(obj) $(dep): $(xerces_c.l.cpp-options)
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/validation/built-in/boolean/makefile b/tests/cxx/parser/validation/built-in/boolean/makefile
index d1f67d3..da5861d 100644
--- a/tests/cxx/parser/validation/built-in/boolean/makefile
+++ b/tests/cxx/parser/validation/built-in/boolean/makefile
@@ -28,7 +28,7 @@ $(driver): $(obj) $(xerces_c.l)
$(obj) $(dep): cpp_options := -I$(src_root)/libxsd
$(obj) $(dep): $(xerces_c.l.cpp-options)
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/validation/built-in/byte/makefile b/tests/cxx/parser/validation/built-in/byte/makefile
index b119b94..2acf537 100644
--- a/tests/cxx/parser/validation/built-in/byte/makefile
+++ b/tests/cxx/parser/validation/built-in/byte/makefile
@@ -28,7 +28,7 @@ $(driver): $(obj) $(xerces_c.l)
$(obj) $(dep): cpp_options := -I$(src_root)/libxsd
$(obj) $(dep): $(xerces_c.l.cpp-options)
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/validation/built-in/date-time/makefile b/tests/cxx/parser/validation/built-in/date-time/makefile
index 8e75e7e..a3856f1 100644
--- a/tests/cxx/parser/validation/built-in/date-time/makefile
+++ b/tests/cxx/parser/validation/built-in/date-time/makefile
@@ -28,7 +28,7 @@ $(driver): $(obj) $(xerces_c.l)
$(obj) $(dep): cpp_options := -I$(src_root)/libxsd
$(obj) $(dep): $(xerces_c.l.cpp-options)
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/validation/built-in/float/makefile b/tests/cxx/parser/validation/built-in/float/makefile
index 0396b54..526bf5d 100644
--- a/tests/cxx/parser/validation/built-in/float/makefile
+++ b/tests/cxx/parser/validation/built-in/float/makefile
@@ -28,7 +28,7 @@ $(driver): $(obj) $(xerces_c.l)
$(obj) $(dep): cpp_options := -I$(src_root)/libxsd
$(obj) $(dep): $(xerces_c.l.cpp-options)
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/validation/built-in/int/makefile b/tests/cxx/parser/validation/built-in/int/makefile
index 4564c41..279a844 100644
--- a/tests/cxx/parser/validation/built-in/int/makefile
+++ b/tests/cxx/parser/validation/built-in/int/makefile
@@ -28,7 +28,7 @@ $(driver): $(obj) $(xerces_c.l)
$(obj) $(dep): cpp_options := -I$(src_root)/libxsd
$(obj) $(dep): $(xerces_c.l.cpp-options)
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/validation/built-in/integer/makefile b/tests/cxx/parser/validation/built-in/integer/makefile
index f5ead41..4a0e3c4 100644
--- a/tests/cxx/parser/validation/built-in/integer/makefile
+++ b/tests/cxx/parser/validation/built-in/integer/makefile
@@ -28,7 +28,7 @@ $(driver): $(obj) $(xerces_c.l)
$(obj) $(dep): cpp_options := -I$(src_root)/libxsd
$(obj) $(dep): $(xerces_c.l.cpp-options)
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/validation/built-in/long/makefile b/tests/cxx/parser/validation/built-in/long/makefile
index a972066..ce710f6 100644
--- a/tests/cxx/parser/validation/built-in/long/makefile
+++ b/tests/cxx/parser/validation/built-in/long/makefile
@@ -28,7 +28,7 @@ $(driver): $(obj) $(xerces_c.l)
$(obj) $(dep): cpp_options := -I$(src_root)/libxsd
$(obj) $(dep): $(xerces_c.l.cpp-options)
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/validation/built-in/qname/makefile b/tests/cxx/parser/validation/built-in/qname/makefile
index 3ecbb93..d887823 100644
--- a/tests/cxx/parser/validation/built-in/qname/makefile
+++ b/tests/cxx/parser/validation/built-in/qname/makefile
@@ -28,7 +28,7 @@ $(driver): $(obj) $(xerces_c.l)
$(obj) $(dep): cpp_options := -I$(src_root)/libxsd
$(obj) $(dep): $(xerces_c.l.cpp-options)
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/validation/built-in/short/makefile b/tests/cxx/parser/validation/built-in/short/makefile
index 5bbcc46..81c5433 100644
--- a/tests/cxx/parser/validation/built-in/short/makefile
+++ b/tests/cxx/parser/validation/built-in/short/makefile
@@ -28,7 +28,7 @@ $(driver): $(obj) $(xerces_c.l)
$(obj) $(dep): cpp_options := -I$(src_root)/libxsd
$(obj) $(dep): $(xerces_c.l.cpp-options)
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/validation/built-in/string/makefile b/tests/cxx/parser/validation/built-in/string/makefile
index 0d9d846..d20c612 100644
--- a/tests/cxx/parser/validation/built-in/string/makefile
+++ b/tests/cxx/parser/validation/built-in/string/makefile
@@ -28,7 +28,7 @@ $(driver): $(obj) $(xerces_c.l)
$(obj) $(dep): cpp_options := -I$(src_root)/libxsd
$(obj) $(dep): $(xerces_c.l.cpp-options)
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/validation/built-in/uri/makefile b/tests/cxx/parser/validation/built-in/uri/makefile
index 4475268..5174a46 100644
--- a/tests/cxx/parser/validation/built-in/uri/makefile
+++ b/tests/cxx/parser/validation/built-in/uri/makefile
@@ -28,7 +28,7 @@ $(driver): $(obj) $(xerces_c.l)
$(obj) $(dep): cpp_options := -I$(src_root)/libxsd
$(obj) $(dep): $(xerces_c.l.cpp-options)
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/parser/validation/choice/makefile b/tests/cxx/parser/validation/choice/makefile
index 2c1123c..cf38433 100644
--- a/tests/cxx/parser/validation/choice/makefile
+++ b/tests/cxx/parser/validation/choice/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-validation
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
diff --git a/tests/cxx/parser/validation/restriction/makefile b/tests/cxx/parser/validation/restriction/makefile
index 90b9f1c..5f58a0b 100644
--- a/tests/cxx/parser/validation/restriction/makefile
+++ b/tests/cxx/parser/validation/restriction/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-validation
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
diff --git a/tests/cxx/parser/validation/sequence/makefile b/tests/cxx/parser/validation/sequence/makefile
index 9f7a0f6..995c2f2 100644
--- a/tests/cxx/parser/validation/sequence/makefile
+++ b/tests/cxx/parser/validation/sequence/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-validation
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
diff --git a/tests/cxx/tree/binary/cdr/makefile b/tests/cxx/tree/binary/cdr/makefile
index da7ebe0..9298961 100644
--- a/tests/cxx/tree/binary/cdr/makefile
+++ b/tests/cxx/tree/binary/cdr/makefile
@@ -41,7 +41,7 @@ $(gen): xsd_options := --generate-insertion ACE_OutputCDR \
--generate-extraction ACE_InputCDR
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/binary/polymorphic/makefile b/tests/cxx/tree/binary/polymorphic/makefile
index 2138eeb..cca1e2c 100644
--- a/tests/cxx/tree/binary/polymorphic/makefile
+++ b/tests/cxx/tree/binary/polymorphic/makefile
@@ -41,7 +41,7 @@ $(gen): xsd_options := --generate-polymorphic --root-element-last \
--generate-insertion ACE_OutputCDR --generate-extraction ACE_InputCDR
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/binary/xdr/makefile b/tests/cxx/tree/binary/xdr/makefile
index f72e161..bf37c4b 100644
--- a/tests/cxx/tree/binary/xdr/makefile
+++ b/tests/cxx/tree/binary/xdr/makefile
@@ -36,7 +36,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-insertion XDR --generate-extraction XDR
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/built-in/makefile b/tests/cxx/tree/built-in/makefile
index d15a15a..e30789f 100644
--- a/tests/cxx/tree/built-in/makefile
+++ b/tests/cxx/tree/built-in/makefile
@@ -46,8 +46,7 @@ $(gen): xsd_options := \
$(gen): $(src_root)/xsd/xsd
-$(call include-dep,$(dep))
-
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/chameleon/makefile b/tests/cxx/tree/chameleon/makefile
index 37fb74d..59f2a7e 100644
--- a/tests/cxx/tree/chameleon/makefile
+++ b/tests/cxx/tree/chameleon/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --root-element root --generate-ostream
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/comparison/makefile b/tests/cxx/tree/comparison/makefile
index 3cbe6f5..be76d46 100644
--- a/tests/cxx/tree/comparison/makefile
+++ b/tests/cxx/tree/comparison/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-comparison
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/compilation/makefile b/tests/cxx/tree/compilation/makefile
index d4201c7..72769f2 100644
--- a/tests/cxx/tree/compilation/makefile
+++ b/tests/cxx/tree/compilation/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-serialization
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/complex/ctor/makefile b/tests/cxx/tree/complex/ctor/makefile
index 6070b44..64ae848 100644
--- a/tests/cxx/tree/complex/ctor/makefile
+++ b/tests/cxx/tree/complex/ctor/makefile
@@ -39,7 +39,7 @@ $(gen): xsd_options := --generate-default-ctor --generate-from-base-ctor \
--generate-comparison
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/containment/makefile b/tests/cxx/tree/containment/makefile
index 58509ae..ea1a160 100644
--- a/tests/cxx/tree/containment/makefile
+++ b/tests/cxx/tree/containment/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-default-ctor
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/default/general/makefile b/tests/cxx/tree/default/general/makefile
index 9ae4bd2..3c555ac 100644
--- a/tests/cxx/tree/default/general/makefile
+++ b/tests/cxx/tree/default/general/makefile
@@ -38,7 +38,7 @@ $(gen): xsd_options := --generate-ostream --generate-serialization \
--generate-default-ctor --generate-from-base-ctor
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/default/omit/makefile b/tests/cxx/tree/default/omit/makefile
index 4a6aaf0..53dd1d1 100644
--- a/tests/cxx/tree/default/omit/makefile
+++ b/tests/cxx/tree/default/omit/makefile
@@ -38,7 +38,7 @@ $(gen): xsd_options := --generate-ostream --generate-serialization \
--generate-default-ctor --generate-from-base-ctor --omit-default-attributes
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/detach/makefile b/tests/cxx/tree/detach/makefile
index b460dfb..44668a2 100644
--- a/tests/cxx/tree/detach/makefile
+++ b/tests/cxx/tree/detach/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-detach --generate-default-ctor
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/encoding/char/iso-8859-1/makefile b/tests/cxx/tree/encoding/char/iso-8859-1/makefile
index 79d4de3..701c20e 100644
--- a/tests/cxx/tree/encoding/char/iso-8859-1/makefile
+++ b/tests/cxx/tree/encoding/char/iso-8859-1/makefile
@@ -38,7 +38,7 @@ $(gen): xsd_options := --char-encoding iso8859-1 --generate-serialization \
--generate-doxygen
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/encoding/char/lcp/makefile b/tests/cxx/tree/encoding/char/lcp/makefile
index 47bf85d..a7a4b82 100644
--- a/tests/cxx/tree/encoding/char/lcp/makefile
+++ b/tests/cxx/tree/encoding/char/lcp/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-serialization --char-encoding lcp
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/encoding/char/utf-8/makefile b/tests/cxx/tree/encoding/char/utf-8/makefile
index aa748df..2224d85 100644
--- a/tests/cxx/tree/encoding/char/utf-8/makefile
+++ b/tests/cxx/tree/encoding/char/utf-8/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-serialization --generate-doxygen
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/encoding/wchar/makefile b/tests/cxx/tree/encoding/wchar/makefile
index c2d81a3..dd601ca 100644
--- a/tests/cxx/tree/encoding/wchar/makefile
+++ b/tests/cxx/tree/encoding/wchar/makefile
@@ -38,7 +38,7 @@ $(gen): xsd_options := --generate-serialization --generate-doxygen \
--char-type wchar_t
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/enumeration/ctor/makefile b/tests/cxx/tree/enumeration/ctor/makefile
index 2086242..4837e7c 100644
--- a/tests/cxx/tree/enumeration/ctor/makefile
+++ b/tests/cxx/tree/enumeration/ctor/makefile
@@ -38,7 +38,7 @@ $(gen): xsd_options := --generate-default-ctor --generate-from-base-ctor \
--generate-doxygen
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/enumeration/inheritance/makefile b/tests/cxx/tree/enumeration/inheritance/makefile
index 6f40509..5677adc 100644
--- a/tests/cxx/tree/enumeration/inheritance/makefile
+++ b/tests/cxx/tree/enumeration/inheritance/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-ostream
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/float/makefile b/tests/cxx/tree/float/makefile
index da12da3..230d682 100644
--- a/tests/cxx/tree/float/makefile
+++ b/tests/cxx/tree/float/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-serialization --root-element-all
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/list/ctor/makefile b/tests/cxx/tree/list/ctor/makefile
index 35581bb..8cfde68 100644
--- a/tests/cxx/tree/list/ctor/makefile
+++ b/tests/cxx/tree/list/ctor/makefile
@@ -38,7 +38,7 @@ $(gen): xsd_options := --generate-default-ctor --generate-from-base-ctor \
--generate-doxygen
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/name-clash/inheritance/makefile b/tests/cxx/tree/name-clash/inheritance/makefile
index 43960fa..d6258ab 100644
--- a/tests/cxx/tree/name-clash/inheritance/makefile
+++ b/tests/cxx/tree/name-clash/inheritance/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-ostream
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/naming/camel/makefile b/tests/cxx/tree/naming/camel/makefile
index e4041d1..b7f862f 100644
--- a/tests/cxx/tree/naming/camel/makefile
+++ b/tests/cxx/tree/naming/camel/makefile
@@ -45,7 +45,7 @@ $(gen): xsd_options := \
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/naming/java/makefile b/tests/cxx/tree/naming/java/makefile
index de7413a..a7d8b29 100644
--- a/tests/cxx/tree/naming/java/makefile
+++ b/tests/cxx/tree/naming/java/makefile
@@ -45,7 +45,7 @@ $(gen): xsd_options := \
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/naming/knr/makefile b/tests/cxx/tree/naming/knr/makefile
index 1104321..0baf083 100644
--- a/tests/cxx/tree/naming/knr/makefile
+++ b/tests/cxx/tree/naming/knr/makefile
@@ -45,7 +45,7 @@ $(gen): xsd_options := \
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/polymorphism/comparison/makefile b/tests/cxx/tree/polymorphism/comparison/makefile
index a52ab6e..5fe465f 100644
--- a/tests/cxx/tree/polymorphism/comparison/makefile
+++ b/tests/cxx/tree/polymorphism/comparison/makefile
@@ -38,7 +38,7 @@ $(gen): xsd_options := --generate-polymorphic --polymorphic-type base \
--generate-comparison
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/polymorphism/ostream/makefile b/tests/cxx/tree/polymorphism/ostream/makefile
index 777d716..daf31ce 100644
--- a/tests/cxx/tree/polymorphism/ostream/makefile
+++ b/tests/cxx/tree/polymorphism/ostream/makefile
@@ -38,7 +38,7 @@ $(gen): xsd_options := --generate-polymorphic --polymorphic-type-all \
--root-element root --generate-ostream
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/polymorphism/same-type/makefile b/tests/cxx/tree/polymorphism/same-type/makefile
index 25b0117..3c66ef5 100644
--- a/tests/cxx/tree/polymorphism/same-type/makefile
+++ b/tests/cxx/tree/polymorphism/same-type/makefile
@@ -38,7 +38,7 @@ $(gen): xsd_options := --generate-ostream --generate-polymorphic \
--root-element root
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/prefix/makefile b/tests/cxx/tree/prefix/makefile
index a0b4778..304ceef 100644
--- a/tests/cxx/tree/prefix/makefile
+++ b/tests/cxx/tree/prefix/makefile
@@ -38,7 +38,7 @@ $(gen): xsd_options := --generate-serialization --generate-polymorphic \
--polymorphic-type foo\#base --root-element root
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/test-template/makefile b/tests/cxx/tree/test-template/makefile
index 31e652a..9fdec91 100644
--- a/tests/cxx/tree/test-template/makefile
+++ b/tests/cxx/tree/test-template/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --generate-ostream
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/types-only/makefile b/tests/cxx/tree/types-only/makefile
index 6846e9f..4b19ab7 100644
--- a/tests/cxx/tree/types-only/makefile
+++ b/tests/cxx/tree/types-only/makefile
@@ -37,7 +37,7 @@ $(gen): xsd := $(out_root)/xsd/xsd
$(gen): xsd_options := --suppress-parsing
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/union/ctor/makefile b/tests/cxx/tree/union/ctor/makefile
index 980f6f4..53b1055 100644
--- a/tests/cxx/tree/union/ctor/makefile
+++ b/tests/cxx/tree/union/ctor/makefile
@@ -38,7 +38,7 @@ $(gen): xsd_options := --generate-default-ctor --generate-from-base-ctor \
--generate-doxygen
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#
diff --git a/tests/cxx/tree/wildcard/makefile b/tests/cxx/tree/wildcard/makefile
index 30aa5b1..0886cf2 100644
--- a/tests/cxx/tree/wildcard/makefile
+++ b/tests/cxx/tree/wildcard/makefile
@@ -38,7 +38,7 @@ $(gen): xsd_options := --generate-wildcard --generate-default-ctor \
--generate-from-base-ctor --generate-serialization --generate-comparison
$(gen): $(out_root)/xsd/xsd
-$(call include-dep,$(dep))
+$(call include-dep,$(dep),$(obj),$(gen))
# Convenience alias for default target.
#