nix build

Signed-off-by: William Casarin <jb55@jb55.com>
This commit is contained in:
William Casarin 2022-04-20 17:15:25 -07:00
parent 60a4613cc1
commit 251031f5a5
2 changed files with 17 additions and 0 deletions

View File

@ -12,6 +12,10 @@ all: nostril
nostril: $(HEADERS) $(OBJS) nostril: $(HEADERS) $(OBJS)
$(CC) $(CFLAGS) $(OBJS) -lsecp256k1 -o $@ $(CC) $(CFLAGS) $(OBJS) -lsecp256k1 -o $@
install: nostril
mkdir -p $(PREFIX)/bin
cp nostril $(PREFIX)/bin
config.h: configurator config.h: configurator
./configurator > $@ ./configurator > $@

13
default.nix Normal file
View File

@ -0,0 +1,13 @@
{ pkgs ? import <nixpkgs> {} }:
with pkgs;
stdenv.mkDerivation {
pname = "nostril";
version = "0.1";
src = ./.;
makeFlags = [ "PREFIX=$(out)" ];
buildInputs = [ secp256k1 ];
}