Merge pull request #2017 from reactormonk/nodejs-binary

Algorithm to find the nodejs binary
This commit is contained in:
Andreas Rumpf
2015-01-28 15:14:39 +01:00
4 changed files with 15 additions and 7 deletions

View File

@@ -15,7 +15,8 @@ when defined(gcc) and defined(windows):
import
commands, lexer, condsyms, options, msgs, nversion, nimconf, ropes,
extccomp, strutils, os, osproc, platform, main, parseopt, service
extccomp, strutils, os, osproc, platform, main, parseopt, service,
nodejs
when hasTinyCBackend:
import tccgen
@@ -67,7 +68,7 @@ proc handleCmdLine() =
else:
ex = quoteShell(
completeCFilePath(changeFileExt(gProjectFull, "js").prependCurDir))
execExternalProgram("node " & ex & ' ' & commands.arguments)
execExternalProgram(findNodeJs() & " " & ex & ' ' & commands.arguments)
else:
var binPath: string
if options.outFile.len > 0: