summaryrefslogtreecommitdiffstats
path: root/diagrams/docs/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'diagrams/docs/Makefile')
-rw-r--r--diagrams/docs/Makefile18
1 files changed, 18 insertions, 0 deletions
diff --git a/diagrams/docs/Makefile b/diagrams/docs/Makefile
new file mode 100644
index 000000000..0ec111697
--- /dev/null
+++ b/diagrams/docs/Makefile
@@ -0,0 +1,18 @@
+DRAWIO ?= /opt/drawio/drawio
+DRAWIO_FLAGS = --export --format svg --transparent --embed-svg-images
+
+SOURCES := $(wildcard *.drawio)
+TARGETS := $(patsubst %.drawio,%.svg,$(SOURCES))
+
+.PHONY:
+all: svg
+
+.PHONY:
+svg: $(TARGETS)
+
+.PHONY:
+clean:
+ rm $(TARGETS)
+
+$(TARGETS): %.svg: %.drawio
+ $(DRAWIO) $(DRAWIO_FLAGS) --output $@ $<