XOXA=../../c
NORMFILES=$(patsubst %.norm, %, $(wildcard *.norm))

%.digest: %.norm
	rm -f $@
	openssl sha1 $< | sed 's/^.*= *//' >$@


all: STAMP.digest

signature-pi-sibling.digest: signature-pi-sibling.norm
	rm -f $@
	sed -n '/(div/,/)div/p' signature-pi-sibling.norm | openssl sha1 >$@

signature-pi-pgp-good.digest: signature-pi-pgp-good.norm
	rm -f $@
	echo "GOODSIG:Xoxa Tester (passphrase 'abc') <none@example.org>" >$@
signature-pi-pgp-sibling.digest: signature-pi-pgp-sibling.norm
	rm -f $@
	echo "GOODSIG:Xoxa Tester (passphrase 'abc') <none@example.org>" >$@

# This STAMP.digest file is largely useless,
# but it serves as a useful target to create all of the .digest files
STAMP.digest: $(NORMFILES:=.digest)
	rm -f STAMP.digest
	cat $(NORMFILES:=.digest) >STAMP.digest

clean:
	rm -f *.digest
