mirror of
ssh://git.janware.com/srv/git/janware/proj/jw-pkg
synced 2026-01-15 03:53:32 +01:00
svg.mk: Add pdf output support (untested)
Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
parent
1673bf2b5b
commit
d6f7f5acfd
1 changed files with 9 additions and 0 deletions
|
|
@ -18,6 +18,12 @@ ifneq ($(filter ico,$(SVG_GENERATE_FORMATS)),)
|
|||
GENERATED_IMAGES += $(GENERATED_ICO)
|
||||
endif
|
||||
|
||||
ifneq ($(filter pdf,$(SVG_GENERATE_FORMATS)),)
|
||||
GENERATED_WIDTHS_ICO ?= 16 32
|
||||
GENERATED_PDF ?= $(patsubst %.svg,%.pdf,$(notdir $(SVG)))
|
||||
GENERATED_IMAGES += $(GENERATED_PDF)
|
||||
endif
|
||||
|
||||
ifneq ($(filter svg,$(SVG_GENERATE_FORMATS)),)
|
||||
IMAGES += $(notdir $(SVG))
|
||||
endif
|
||||
|
|
@ -34,6 +40,9 @@ clean.images:
|
|||
inkscape -w $(shell echo $* | sed 's/.*-//') \
|
||||
--export-png=$@ copied-$(shell echo $* | sed 's/-[0-9]\+$$//').svg
|
||||
|
||||
%.pdf: copied-%.svg
|
||||
inkscape --export-pdf=$@ $<
|
||||
|
||||
copied-%.svg: $(SVG)
|
||||
@echo $^
|
||||
cp $(filter %$*.svg, $^) $@.tmp
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue