2.10: update installation
[lttng-docs.git] / Makefile
CommitLineData
7adf7ee2
PP
1# Copyright 2016 Philippe Proulx <pproulx@efficios.com>
2
f0287ae1
PP
3CONF = asciidoc.html5.conf
4PREFIX = lttng-docs
7adf7ee2 5ALLVERSIONS = $(sort $(wildcard 2.*))
f0287ae1
PP
6
7ASCIIDOC = asciidoc -v -f $(CONF) -a source-highlighter=pygments
8RM = rm -rf
9
7adf7ee2
PP
10define vrule
11$(1)/$(PREFIX)-$(1).html: $(1)/$(PREFIX)-$(1).txt $(CONF)
12 $(ASCIIDOC) -a "lttng_version=$(1)" $(1)/$(PREFIX)-$(1).txt
f0287ae1 13
7adf7ee2 14.PHONY: $(1)
f0287ae1 15
7adf7ee2 16$(1): $(1)/$(PREFIX)-$(1).html
4026b681
PP
17
18view-$(1):
19 xdg-open $(1)/$(PREFIX)-$(1).html
20
21.PHONY: view-$(1)
7adf7ee2 22endef
f0287ae1 23
7adf7ee2 24.PHONY: all
f0287ae1 25
7adf7ee2 26all: $(ALLVERSIONS)
f0287ae1 27
7adf7ee2 28$(foreach v,$(ALLVERSIONS),$(eval $(call vrule,$(v))))
f0287ae1
PP
29
30.PHONY: clean
31
32clean:
7adf7ee2 33 $(RM) $(foreach v,$(ALLVERSIONS),$(v)/$(PREFIX)-$(v).html)
This page took 0.023517 seconds and 4 git commands to generate.