forked from florencewattsense/box_install_guide
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
32 lines (24 loc) · 671 Bytes
/
Makefile
File metadata and controls
32 lines (24 loc) · 671 Bytes
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
LANGS=fr en
OUTPUT:=output
OUTFILES=$(foreach l,$(LANGS),$(OUTPUT)/guide_$(l).ext)
all: html docbook pdf
html: $(OUTFILES:.ext=.html)
docbook: $(OUTFILES:.ext=.xml)
pdf: $(OUTFILES:.ext=.pdf)
IMAGES=images/*
prep:
mkdir -p $(OUTPUT)
ln -sf $(shell pwd)/images $(OUTPUT)/images
$(OUTPUT)/guide_%.html: guide_%.adoc prep $(IMAGES)
@echo $@
asciidoctor -o $@ $<
$(OUTPUT)/guide_%.xml: guide_%.adoc prep $(IMAGES)
asciidoctor -o $@ -b docbook5 $<
$(OUTPUT)/guide_%.pdf: $(OUTPUT)/guide_%.xml prep dblatex.xsl
dblatex --pdf -p dblatex.xsl -O $(OUTPUT) $<
clean:
-rm $(OUTPUT)/*.html
-rm $(OUTPUT)/*.xml
-rm $(OUTPUT)/*.pdf
-rm $(OUTPUT)/images
.PHONY: clean