logos-storage-proofs/codex_storage_proofs.nim

20 lines
480 B
Nim
Raw Normal View History

import std/os
2023-12-22 18:24:12 -07:00
import std/strutils
import std/sha1
import std/macros
2023-12-22 18:07:17 -07:00
const
currentDir = currentSourcePath().parentDir()
2023-12-22 18:24:12 -07:00
libPath* = currentDir/"target"/"release"/"libcodex_storage_proofs.a"
2023-12-22 18:07:17 -07:00
static:
2023-12-22 18:24:12 -07:00
let cmd = "cargo build --release"
2023-12-22 18:28:15 -07:00
warning "\nBuilding codex-storage-proofs: " & cmd
2023-12-22 18:07:17 -07:00
let (output, exitCode) = gorgeEx cmd
2023-12-22 18:24:12 -07:00
for ln in output.splitLines():
2023-12-22 18:28:15 -07:00
warning("cargo> " & ln)
2023-12-22 18:07:17 -07:00
if exitCode != 0:
raise (ref Defect)(msg: "Failed to build codex-storage-proofs")