nim-ethash/ethash.nimble

31 lines
910 B
Plaintext
Raw Normal View History

packageName = "ethash"
2018-02-15 10:23:42 +00:00
version = "0.0.1"
author = "Status Research & Development GmbH"
description = "A Nim implementation of Ethash, the Ethereum proof-of-work hashing function"
license = "Apache License 2.0"
2018-02-15 10:23:42 +00:00
srcDir = "src"
### Dependencies
2018-03-02 09:12:31 +00:00
requires "nim >= 0.18.0", "keccak_tiny >= 0.1.0"
proc test(name: string, lang: string = "c") =
if not dirExists "build":
mkDir "build"
if not dirExists "nimcache":
mkDir "nimcache"
--run
--nimcache: "nimcache"
switch("out", ("./build/" & name))
setCommand lang, "tests/" & name & ".nim"
2018-02-27 10:29:46 +00:00
task test, "Run Proof-of-Work tests (without mining)":
test "all_tests"
task test_mining, "Run Proof-of-Work and mining tests (test in release mode + OpenMP + march=native)":
2018-02-27 10:29:46 +00:00
switch("define", "release")
switch("define", "openmp")
switch("define", "march_native")
2018-02-27 10:29:46 +00:00
switch("define", "ethash_mining")
2018-02-27 18:31:25 +00:00
test "all_tests"