2018-02-13 18:20:27 +00:00
|
|
|
packageName = "eth_keys"
|
2018-02-08 09:51:13 +00:00
|
|
|
version = "0.0.1"
|
|
|
|
author = "Status Research & Development GmbH"
|
|
|
|
description = "A reimplementation in pure Nim of eth-keys, the common API for Ethereum key operations."
|
2018-03-02 10:57:43 +00:00
|
|
|
license = "Apache License 2.0 or MIT"
|
2018-02-08 09:51:13 +00:00
|
|
|
srcDir = "src"
|
|
|
|
|
|
|
|
### Dependencies
|
2018-02-14 15:24:29 +00:00
|
|
|
|
2018-03-02 09:11:55 +00:00
|
|
|
requires "nim >= 0.18.0", "keccak_tiny >= 0.1.0", "ttmath >= 0.1.0", "nimSHA2", "secp256k1"
|
2018-02-08 09:51:13 +00:00
|
|
|
|
2018-02-13 18:20:27 +00:00
|
|
|
proc test(name: string, lang: string = "cpp") =
|
2018-02-08 09:51:13 +00:00
|
|
|
if not dirExists "build":
|
2018-02-13 18:20:27 +00:00
|
|
|
mkDir "build"
|
2018-02-08 09:51:13 +00:00
|
|
|
if not dirExists "nimcache":
|
|
|
|
mkDir "nimcache"
|
|
|
|
--run
|
|
|
|
--nimcache: "nimcache"
|
|
|
|
switch("out", ("./build/" & name))
|
2018-02-13 18:20:27 +00:00
|
|
|
setCommand lang, "tests/" & name & ".nim"
|
|
|
|
|
2018-03-01 15:33:34 +00:00
|
|
|
task test, "Run all tests - libsecp256k1 backend":
|
|
|
|
test "all_tests"
|
|
|
|
|
|
|
|
task test_backend_native, "Run all tests - pure Nim backend":
|
|
|
|
switch("define", "backend_native")
|
2018-02-27 17:41:16 +00:00
|
|
|
test "all_tests"
|