2018-01-27 16:18:38 +00:00
|
|
|
packageName = "rocksdb"
|
2024-03-05 03:12:37 +00:00
|
|
|
version = "0.4.0"
|
2018-01-27 16:18:38 +00:00
|
|
|
author = "Status Research & Development GmbH"
|
|
|
|
description = "A wrapper for Facebook's RocksDB, an embeddable, persistent key-value store for fast storage"
|
|
|
|
license = "Apache License 2.0 or GPLv2"
|
2018-07-04 12:09:03 +00:00
|
|
|
skipDirs = @["examples", "tests"]
|
2022-03-22 09:02:39 +00:00
|
|
|
mode = ScriptMode.Verbose
|
2018-01-27 16:18:38 +00:00
|
|
|
|
|
|
|
### Dependencies
|
2024-03-05 03:12:37 +00:00
|
|
|
requires "nim >= 1.6",
|
2019-07-07 10:11:27 +00:00
|
|
|
"stew",
|
2024-03-05 03:12:37 +00:00
|
|
|
"tempfile",
|
|
|
|
"unittest2"
|
2018-02-03 23:55:41 +00:00
|
|
|
|
2022-01-11 01:39:31 +00:00
|
|
|
proc test(args, path: string) =
|
2018-02-03 23:55:41 +00:00
|
|
|
if not dirExists "build":
|
2018-02-05 21:19:33 +00:00
|
|
|
mkDir "build"
|
2022-01-11 01:39:31 +00:00
|
|
|
exec "nim " & getEnv("TEST_LANG", "c") & " " & getEnv("NIMFLAGS") & " " & args &
|
|
|
|
" --outdir:build -r --hints:off --threads:on --skipParentCfg " & path
|
2018-02-03 23:55:41 +00:00
|
|
|
|
2019-01-10 23:39:17 +00:00
|
|
|
task test, "Run tests":
|
2024-03-05 03:12:37 +00:00
|
|
|
test "", "tests/test_all.nim"
|
2022-03-22 09:02:39 +00:00
|
|
|
# Too troublesome to install "librocksdb.a" in CI, but this is how we would
|
|
|
|
# test it (we need the C++ linker profile because it's a C++ library):
|
2024-03-05 03:12:37 +00:00
|
|
|
# test "-d:LibrocksbStaticArgs='-l:librocksdb.a' --gcc.linkerexe=g++", "tests/test_all.nim"
|
2018-06-24 23:13:10 +00:00
|
|
|
|