Added support for --genDeps on JS backend (#10320)

This commit is contained in:
nepeckman
2019-01-15 16:58:44 -05:00
committed by Andreas Rumpf
parent ef769e20b3
commit 7920dc2898

View File

@@ -92,6 +92,7 @@ proc commandJsonScript(graph: ModuleGraph) =
when not defined(leanCompiler):
proc commandCompileToJS(graph: ModuleGraph) =
let conf = graph.config
#incl(gGlobalOptions, optSafeCode)
setTarget(graph.config.target, osJS, cpuJS)
#initDefines()
@@ -100,6 +101,8 @@ when not defined(leanCompiler):
semanticPasses(graph)
registerPass(graph, JSgenPass)
compileProject(graph)
if optGenScript in graph.config.globalOptions:
writeDepsFile(graph, toGeneratedFile(conf, conf.projectFull, ""))
proc interactivePasses(graph: ModuleGraph) =
initDefines(graph.config.symbols)