зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1461714 - Run node in export; r=ochameau,nalexander
In bug 1461714 we run node.py to generate main.js in the objdir, and use FINAL_TARGET_FILES to install it into dist. However, when both rules are run in parallel in the misc tier, the install target may pick up the main.js file from the srcdir via VPATH, so we end up with the wrong file in dist. This causes some mochitests to fail with "uncaught exception - SyntaxError: import declarations may only appear at top level of a module at @resource://devtools/client/debugger/new/src/main.js:7:undefined" The workaround here is to run these node.py invocations (which always write to node.stub) in the export tier, so that when the install target in misc is processed, the objdir version of the file is always present and takes precedence. A better fix would probably be to remove our reliance on VPATH, and just pass in the path to files in the srcdir when they are required. That could potentially be a major overhaul, however. MozReview-Commit-ID: JZ04C7zJPbX Differential Revision: https://phabricator.services.mozilla.com/D7770 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
ec93421a8f
Коммит
5c85018da7
|
@ -1170,6 +1170,7 @@ class GeneratedFile(ContextDerived):
|
|||
'.inc',
|
||||
'.py',
|
||||
'.rs',
|
||||
'node.stub', # To avoid VPATH issues with installing node files: https://bugzilla.mozilla.org/show_bug.cgi?id=1461714#c55
|
||||
)
|
||||
self.required_for_compile = [f for f in self.outputs if f.endswith(suffixes) or 'stl_wrappers/' in f]
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче