config: add support for inkscape 1.x

There are breaking command line option changes between 0.9.x and 1.x.
This commit is contained in:
David Lechner
2020-04-02 20:44:36 -05:00
parent 9e353b4bd3
commit 402991fce8
+10 -1
View File
@@ -13,4 +13,13 @@ clean:
rm -f $(DIAGRAMS)
$(OUT_DIR)/%$(POSTFIX).png: $(SRC_DIR)/%.svg
inkscape --file=$(DIR)/$< --export-area-drawing --export-png=$(DIR)/$@
if inkscape --version | grep -q "Inkscape 0"; then \
inkscape --file=$(DIR)/$< --export-area-drawing --export-png=$(DIR)/$@; \
else \
inkscape \
--export-area-drawing \
--export-background=white \
--export-background-opacity=1.0 \
--export-file=$(DIR)/$@ \
$(DIR)/$<; \
fi