From bf4353663b2caa7e3492905f14fbfbc93758b560 Mon Sep 17 00:00:00 2001 From: Nicolas Dandrimont <nicolas@dandrimont.eu> Date: Thu, 9 Jul 2020 19:35:21 +0200 Subject: [PATCH] Rework dia -> pdf pipeline for inkscape 1.0 - Use dia directly to convert from .dia to .svg (inkscape would use dia via a plugin anyway) - Add proper runes to detect inkscape >= 1 and use the export options for that. --- docs/images/Makefile | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/docs/images/Makefile b/docs/images/Makefile index ddc859da..890d6fb9 100644 --- a/docs/images/Makefile +++ b/docs/images/Makefile @@ -6,12 +6,15 @@ BUILD_TARGETS += $(MERKLE_DAG) all: $(BUILD_TARGETS) - %.svg: %.dia - inkscape -l $@ $< + dia -e $@ $< -%.pdf: %.dia - inkscape -A $@ $< +%.pdf: %.svg + set -e; if [ $$(inkscape --version 2>/dev/null | grep -Eo '[0-9]+' | head -1) -gt 0 ]; then \ + inkscape -o $@ $< ; \ + else \ + inkscape -A $@ $< ; \ + fi clean: -rm -f $(BUILD_TARGETS) -- GitLab