blob: 192668c06684a3d19286370690c847f32abd489b (
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
|
# Makefile
# Build Targets
TARGETS := priv unpriv
.PHONY: all $(TARGETS)
all: $(TARGETS)
ASCIIDOCTOR_OPTS := --attribute=mathematical-format=svg \
--failure-level=ERROR \
--require=asciidoctor-bibtex \
--require=asciidoctor-diagram \
--require=asciidoctor-mathematical \
--trace
SRCDIR := ../src
# Privileged ISA
priv: priv-isa-asciidoc.pdf
priv-isa-asciidoc.pdf: $(SRCDIR)/riscv-privileged.adoc
@echo "Building Privileged ISA"
rm -f $@.tmp
asciidoctor-pdf $(ASCIIDOCTOR_OPTS) --out-file=$@.tmp $<
mv $@.tmp $@
# Unprivileged ISA
unpriv: unpriv-isa-asciidoc.pdf
unpriv-isa-asciidoc.pdf: $(SRCDIR)/riscv-isa-unpr-conv-review.adoc
@echo "Building Unprivileged ISA"
rm -f $@.tmp
asciidoctor-pdf $(ASCIIDOCTOR_OPTS) --out-file=$@.tmp $<
mv $@.tmp $@
clean:
@if [ -f priv-isa-asciidoc.pdf ]; then \
echo "Removing priv-isa-asciidoc.pdf"; \
rm -f priv-isa-asciidoc.pdf; \
fi
@if [ -f unpriv-isa-asciidoc.pdf ]; then \
echo "Removing unpriv-isa-asciidoc.pdf"; \
rm -f unpriv-isa-asciidoc.pdf; \
fi
|