2022-04-14 10:52:29 -04:00
|
|
|
|
2022-04-14 15:35:26 -04:00
|
|
|
CFLAGS = -Wall -Og
|
|
|
|
OBJS = sha256.o nostril.o aes.o base64.o
|
2022-04-14 10:52:29 -04:00
|
|
|
HEADERS = hex.h random.h config.h sha256.h
|
|
|
|
|
|
|
|
all: nostril
|
|
|
|
|
2022-04-14 11:14:13 -04:00
|
|
|
%.o: %.c config.h
|
|
|
|
@echo "cc $<"
|
2022-04-14 11:17:10 -04:00
|
|
|
@$(CC) $(CFLAGS) -c $< -o $@
|
2022-04-14 11:14:13 -04:00
|
|
|
|
2022-04-14 11:11:17 -04:00
|
|
|
nostril: $(HEADERS) $(OBJS)
|
2022-04-14 11:17:10 -04:00
|
|
|
$(CC) $(CFLAGS) $(OBJS) -lsecp256k1 -o $@
|
2022-04-14 10:52:29 -04:00
|
|
|
|
2022-04-20 20:15:25 -04:00
|
|
|
install: nostril
|
|
|
|
mkdir -p $(PREFIX)/bin
|
|
|
|
cp nostril $(PREFIX)/bin
|
|
|
|
|
2022-04-14 10:52:29 -04:00
|
|
|
config.h: configurator
|
|
|
|
./configurator > $@
|
|
|
|
|
|
|
|
configurator: configurator.c
|
|
|
|
$(CC) $< -o $@
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f nostril *.o
|
|
|
|
|
|
|
|
tags: fake
|
|
|
|
ctags *.c *.h
|
|
|
|
|
|
|
|
.PHONY: fake
|