keksum_genesis_3 1 CFLAGS = -O1 -ansi -pedantic -Wall -Wextra -Winit-self
keksum_genesis_3 2 LDFLAGS = -static
keksum_genesis_3 3
keksum_genesis_3 4 keksum: keccak.o io.o main.o
keksum_genesis_3 5 $(CC) -o $@ $(LDFLAGS) $^
keksum_genesis_3 6
keksum_genesis_3 7 ktest: ktest.o io.o
keksum_genesis_3 8 $(CC) -o $@ $(LDFLAGS) $^
keksum_genesis_3 9
keksum_genesis_3 10 check: keksum ktest
keksum_genesis_3 11 ./ktest
keksum_genesis_3 12 sh test-sponge.sh
keksum_genesis_3 13
keksum_genesis_3 14 clean:
keksum_genesis_3 15 rm -f keksum ktest testvectors.h *.o
keksum_genesis_3 16
keksum_genesis_3 17 ktest.o: keccak.c
keksum_genesis_3 18 $(CC) -o $@ $(CFLAGS) -DTEST -c $<
keksum_genesis_3 19
keksum_genesis_3 20 testvectors.h: munge-testvecs.py testvectorszero.txt testvectorsnonzero.txt
keksum_genesis_3 21 python2 $^ >$@.tmp && mv $@.tmp $@
keksum_genesis_3 22
keksum_genesis_3 23 # Header deps
keksum_genesis_3 24 keccak.o: io.h
keksum_genesis_3 25 ktest.o: io.h testvectors.h
keksum_genesis_3 26 io.o: io.h
keksum_genesis_3 27 main.o: io.h