diff options
author | nepeckman <nepeckman@protonmail.com> | 2019-01-15 16:58:44 -0500 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2019-01-15 22:58:44 +0100 |
commit | 7920dc2898b9518a89c4a588dac2bcdea5658a92 (patch) | |
tree | 2f245575b4c4dfc1983e03fd443b1a82342244e6 /compiler/main.nim | |
parent | ef769e20b3b53de4a6940ae5cbc6751647e402f7 (diff) | |
download | Nim-7920dc2898b9518a89c4a588dac2bcdea5658a92.tar.gz |
Added support for --genDeps on JS backend (#10320)
Diffstat (limited to 'compiler/main.nim')
-rw-r--r-- | compiler/main.nim | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/compiler/main.nim b/compiler/main.nim index b5f7e8364..49c2666ea 100644 --- a/compiler/main.nim +++ b/compiler/main.nim @@ -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) |