nostrdb

an unfairly fast embedded nostr database backed by lmdb
git clone git://jb55.com/nostrdb
Log | Files | Refs | Submodules | README | LICENSE

build.sh (473B)


      1 #!/bin/sh
      2 cd $(dirname $0)
      3 
      4 FLATBUFFERS_DIR=../..
      5 NAME=myissue
      6 SCHEMA=eclectic.fbs
      7 OUT=build
      8 
      9 FLATCC_EXE=$FLATBUFFERS_DIR/bin/flatcc
     10 FLATCC_INCLUDE=$FLATBUFFERS_DIR/include
     11 FLATCC_LIB=$FLATBUFFERS_DIR/lib
     12 
     13 mkdir -p $OUT
     14 $FLATCC_EXE --outfile $OUT/${NAME}_generated.h -a $SCHEMA || exit 1
     15 cc -I$FLATCC_INCLUDE -g -o $OUT/$NAME $NAME.c -L$FLATCC_LIB -lflatccrt_d || exit 1
     16 echo "running $OUT/$NAME"
     17 if $OUT/$NAME; then
     18     echo "success"
     19 else
     20     echo "failed"
     21     exit 1
     22 fi