Merge pull request #252 from Jeff-Ciesielski/jeffc/issue_215

Add binDir checking/auto creation.  Fixes #215
This commit is contained in:
Dominik Picheta 2016-09-19 19:30:56 +02:00 committed by GitHub
commit acb5e86fef

View file

@ -313,6 +313,11 @@ proc buildFromDir(pkgInfo: PackageInfo, paths: seq[string], forRelease: bool) =
let outputOpt = "-o:\"" & pkgInfo.getOutputDir(bin) & "\""
echo("Building ", pkginfo.name, "/", bin, " using ", pkgInfo.backend,
" backend...")
let outputDir = pkgInfo.getOutputDir("")
if not existsDir(outputDir):
createDir(outputDir)
try:
doCmd(getNimBin() & " $# $# --noBabelPath $# $# \"$#\"" %
[pkgInfo.backend, releaseOpt, args, outputOpt,