2018-06-26 18:08:11 +00:00
|
|
|
packageName = "json_rpc"
|
|
|
|
version = "0.0.2"
|
2018-03-02 13:01:30 +00:00
|
|
|
author = "Status Research & Development GmbH"
|
|
|
|
description = "Ethereum remote procedure calls"
|
|
|
|
license = "Apache License 2.0"
|
2018-05-22 19:42:14 +00:00
|
|
|
skipDirs = @["tests"]
|
2018-03-02 13:01:30 +00:00
|
|
|
|
|
|
|
### Dependencies
|
2021-03-26 12:17:00 +00:00
|
|
|
requires "nim >= 1.2.0",
|
2018-05-09 14:08:03 +00:00
|
|
|
"nimcrypto",
|
2018-06-07 07:02:14 +00:00
|
|
|
"stint",
|
2019-02-06 17:27:58 +00:00
|
|
|
"chronos",
|
2018-09-15 20:50:44 +00:00
|
|
|
"httputils",
|
2019-06-12 13:44:19 +00:00
|
|
|
"chronicles",
|
2020-09-21 04:37:29 +00:00
|
|
|
"https://github.com/status-im/news#status",
|
2019-06-20 12:46:39 +00:00
|
|
|
"chronicles",
|
|
|
|
"json_serialization"
|
2018-04-11 11:48:34 +00:00
|
|
|
|
2021-01-07 11:12:27 +00:00
|
|
|
proc getLang(): string =
|
|
|
|
# Compilation language is controlled by TEST_LANG
|
|
|
|
result = "c"
|
|
|
|
if existsEnv"TEST_LANG":
|
|
|
|
result = getEnv"TEST_LANG"
|
|
|
|
|
2019-12-02 11:14:00 +00:00
|
|
|
proc buildBinary(name: string, srcDir = "./", params = "", cmdParams = "", lang = "c") =
|
|
|
|
if not dirExists "build":
|
|
|
|
mkDir "build"
|
|
|
|
exec "nim " & lang & " --out:./build/" & name & " " & params & " " & srcDir & name & ".nim" & " " & cmdParams
|
2018-04-11 11:48:34 +00:00
|
|
|
|
|
|
|
task test, "run tests":
|
2021-01-07 11:12:27 +00:00
|
|
|
buildBinary "all", "tests/", "-r -f --hints:off --debuginfo --path:'.' --threads:on -d:chronicles_log_level=ERROR", getLang()
|