copy in submodule and build.sh

This commit is contained in:
benbierens 2024-05-09 10:18:06 +02:00
parent 69f86fe38c
commit ab4e190d47
No known key found for this signature in database
GPG Key ID: 877D2C2E09A22F3A
3 changed files with 20 additions and 0 deletions

3
.gitmodules vendored Normal file
View File

@ -0,0 +1,3 @@
[submodule "sources"]
path = sources
url = https://github.com/google/leveldb

16
build.sh Normal file
View File

@ -0,0 +1,16 @@
#!/bin/bash
root=$(dirname "$0")
# install nimterop, if not already installed
if ! [ -x "$(command -v toast)" ]; then
nimble install -y nimterop@0.6.13
fi
# generate nim wrapper with nimterop
toast \
--compile="${root}/sources/randombytes.c" \
--compile="${root}/sources/hazmat.c" \
--pnim \
--noHeader \
"${root}/sources/randombytes.h" \
"${root}/sources/hazmat.h" > "${root}/sss/cwrapper.nim"

1
sources Submodule

@ -0,0 +1 @@
Subproject commit 99b3c03b3284f5886f9ef9a4ef703d57373e61be