File: Makefile

package info (click to toggle)
stateless-openpgp-docs 13.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 380 kB
  • sloc: sh: 951; ansic: 279; makefile: 49; python: 36
file content (31 lines) | stat: -rw-r--r-- 607 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#!/usr/bin/make -f

# dependencies:

# apt install weasyprint xml2rfc ruby-kramdown-rfc2629

draft = sop
OUTPUT = $(draft).txt $(draft).html $(draft).xml $(draft).pdf
INCLUSIONS = sop.h test/simple-sop-test test/setup-sopv-test test/sopv-test

all: $(OUTPUT)

%.xml: $(draft).md $(INCLUSIONS)
	kramdown-rfc --v3 < $< > $@.tmp
	mv $@.tmp $@

%.html: %.xml
	xml2rfc $< --html -o $@

%.txt: %.xml
	xml2rfc $< --text -o $@

%.pdf: %.xml
	xml2rfc $< --pdf -o $@

clean:
	-rm -rf $(OUTPUT) manpages/*.1 .refcache metadata.min.js

check:
	codespell --ignore-words .ignore-words $(draft).md
.PHONY: clean all check