summaryrefslogtreecommitdiff
path: root/Makefile
blob: 2f62fac23664a93fbdf271e895d0f63661844f88 (plain)
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
all: public/index.html
all: public/style.css
all: public/jarmon-style/jquerytools.tabs.tabs-no-images.css
all: public/jarmon-style/style.css

NET-%:
	date > $@

.DELETE_ON_ERROR:
.SECONDARY:

# bin/

bin/%: bin-src/%.go bin-src/util $(wildcard bin-src/util/*.go)
	go build -o $@ $<

bin/%: bin-src/%
	@mkdir -p '$(@D)'
	ln -srTf '$<' '$@'

# public/

public/%: public-src/%
	@mkdir -p '$(@D)'
	ln -srTf '$<' '$@'

public/index.html: public/tls.html.part public/crtsh.html.part public/diff.html.part public/jarmon.html.in

public/crtsh.pem: bin/crtsh-getcerts cfg/domains.txt NET-crtsh
	@mkdir -p '$(@D)'
	bin/crtsh-getcerts $$(sed 's/#.*//' cfg/domains.txt) > $@

public/tls.pem: bin/tls-getcerts cfg/sockets.txt NET-tls
	@mkdir -p '$(@D)'
	bin/tls-getcerts $$(sed 's/#.*//' cfg/sockets.txt) > $@

public/diff.pem: bin/pem-diff public/tls.pem public/crtsh.pem
	$^ > $@

public/tls.html.part public/crtsh.html.part public/diff.html.part: \
public/%.html.part: public/%.pem bin/%-pem2html
	bin/$*-pem2html < $< > $@

public/%: public/%.gen
	$^ > $@

public/%.css: public/%.scss
	scss $< $@