diff --git a/dom/bindings/Makefile.in b/dom/bindings/Makefile.in index b304623b8b05..84518efde85f 100644 --- a/dom/bindings/Makefile.in +++ b/dom/bindings/Makefile.in @@ -6,6 +6,15 @@ webidl_base := $(topsrcdir)/dom/webidl ifdef COMPILE_ENVIRONMENT +# Akin to GLOBAL_DEPS, but set early enough that webidlsrcs.mk +# can make use of them as dependencies. +WEBIDL_PP_DEPS := \ + backend.mk \ + Makefile \ + $(DEPTH)/config/autoconf.mk \ + $(topsrcdir)/config/config.mk \ + $(NULL) + # Generated by moz.build include webidlsrcs.mk diff --git a/python/mozbuild/mozbuild/backend/recursivemake.py b/python/mozbuild/mozbuild/backend/recursivemake.py index 22c5c46d185e..1c8574104af3 100644 --- a/python/mozbuild/mozbuild/backend/recursivemake.py +++ b/python/mozbuild/mozbuild/backend/recursivemake.py @@ -1782,7 +1782,10 @@ class RecursiveMakeBackend(CommonBackend): for source in sorted(webidls.all_preprocessed_sources()): basename = os.path.basename(source) rule = mk.create_rule([basename]) - rule.add_dependencies([source, '$(GLOBAL_DEPS)']) + # GLOBAL_DEPS would be used here, but due to the include order of + # our makefiles it's not set early enough to be useful, so we use + # WEBIDL_PP_DEPS, which has analagous content. + rule.add_dependencies([source, '$(WEBIDL_PP_DEPS)']) rule.add_commands([ # Remove the file before writing so bindings that go from # static to preprocessed don't end up writing to a symlink,