koch winrelease: also bundle c2nim for Windows [backport]
This commit is contained in:
parent
864c3e874c
commit
e33544ad13
1 changed files with 8 additions and 1 deletions
9
koch.nim
9
koch.nim
|
|
@ -89,7 +89,7 @@ template withDir(dir, body) =
|
||||||
setCurrentDir(dir)
|
setCurrentDir(dir)
|
||||||
body
|
body
|
||||||
finally:
|
finally:
|
||||||
setCurrentdir(old)
|
setCurrentDir(old)
|
||||||
|
|
||||||
let origDir = getCurrentDir()
|
let origDir = getCurrentDir()
|
||||||
setCurrentDir(getAppDir())
|
setCurrentDir(getAppDir())
|
||||||
|
|
@ -128,6 +128,11 @@ proc bundleNimbleSrc(latest: bool) =
|
||||||
exec("git checkout -f stable")
|
exec("git checkout -f stable")
|
||||||
exec("git pull")
|
exec("git pull")
|
||||||
|
|
||||||
|
proc bundleC2nim() =
|
||||||
|
if not dirExists("dist/c2nim/.git"):
|
||||||
|
exec("git clone https://github.com/nim-lang/c2nim.git dist/c2nim")
|
||||||
|
nimCompile("dist/c2nim/c2nim", options = "--noNimblePath --path:.")
|
||||||
|
|
||||||
proc bundleNimbleExe(latest: bool) =
|
proc bundleNimbleExe(latest: bool) =
|
||||||
bundleNimbleSrc(latest)
|
bundleNimbleSrc(latest)
|
||||||
# installer.ini expects it under $nim/bin
|
# installer.ini expects it under $nim/bin
|
||||||
|
|
@ -172,6 +177,7 @@ proc bundleWinTools() =
|
||||||
buildVccTool()
|
buildVccTool()
|
||||||
nimCompile("tools/nimgrab.nim", options = "-d:ssl")
|
nimCompile("tools/nimgrab.nim", options = "-d:ssl")
|
||||||
nimCompile("tools/nimgrep.nim")
|
nimCompile("tools/nimgrep.nim")
|
||||||
|
bundleC2nim()
|
||||||
when false:
|
when false:
|
||||||
# not yet a tool worth including
|
# not yet a tool worth including
|
||||||
nimCompile(r"tools\downloader.nim", options = r"--cc:vcc --app:gui -d:ssl --noNimblePath --path:..\ui")
|
nimCompile(r"tools\downloader.nim", options = r"--cc:vcc --app:gui -d:ssl --noNimblePath --path:..\ui")
|
||||||
|
|
@ -621,6 +627,7 @@ when isMainModule:
|
||||||
buildNimble(isLatest())
|
buildNimble(isLatest())
|
||||||
of "pushcsource", "pushcsources": pushCsources()
|
of "pushcsource", "pushcsources": pushCsources()
|
||||||
of "valgrind": valgrind(op.cmdLineRest)
|
of "valgrind": valgrind(op.cmdLineRest)
|
||||||
|
of "c2nim": bundleC2nim()
|
||||||
else: showHelp()
|
else: showHelp()
|
||||||
break
|
break
|
||||||
of cmdEnd: break
|
of cmdEnd: break
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue