DARK = 363636
WHITE = ffffff
+# rsvg-convert command line
+RSVG_CONVERT = rsvg-convert --keep-aspect-ratio
+
# Inkscape command line
INKSCAPE = inkscape $< --export-filename=$@
# Converts the logo to PDF
%.pdf: %.svg
mkdir -p $(dir $@)
- $(INKSCAPE)
+ rsvg-convert --format=pdf1.7 $< > $@
# Converts the logo to PNG
%/logo-512.png: %/logo.svg
mkdir -p $(dir $@) && \
- $(INKSCAPE) --export-width=512
+ $(RSVG_CONVERT) --format=png --width=512 $< > $@
%/logo-1024.png: %/logo.svg
mkdir -p $(dir $@) && \
- $(INKSCAPE) --export-width=1024
+ $(RSVG_CONVERT) --format=png --width=1024 $< > $@
%/logo-2048.png: %/logo.svg
mkdir -p $(dir $@) && \
- $(INKSCAPE) --export-width=2048
+ $(RSVG_CONVERT) --format=png --width=2048 $< > $@
%/logo-4096.png: %/logo.svg
mkdir -p $(dir $@) && \
- $(INKSCAPE) --export-width=4096
+ $(RSVG_CONVERT) --format=png --width=4096 $< > $@
# Converts the square logo to PNG
%/logo-square-512x512.png: %/logo-square.svg
mkdir -p $(dir $@) && \
- $(INKSCAPE) --export-width=512
+ $(RSVG_CONVERT) --format=png --width=512 $< > $@
%/logo-square-1024x1024.png: %/logo-square.svg
mkdir -p $(dir $@) && \
- $(INKSCAPE) --export-width=1024
+ $(RSVG_CONVERT) --format=png --width=1024 $< > $@
%/logo-square-2048x2048.png: %/logo-square.svg
mkdir -p $(dir $@) && \
- $(INKSCAPE) --export-width=2048
+ $(RSVG_CONVERT) --format=png --width=2048 $< > $@
%/logo-square-4096x4096.png: %/logo-square.svg
mkdir -p $(dir $@) && \
- $(INKSCAPE) --export-width=4096
+ $(RSVG_CONVERT) --format=png --width=4096 $< > $@
# Converts the favicon to PNG
%/favicon-16x16.png: %/favicon.svg
mkdir -p $(dir $@) && \
- $(INKSCAPE) --export-width=16
+ $(RSVG_CONVERT) --format=png --width=16 $< > $@
%/favicon-32x32.png: %/favicon.svg
mkdir -p $(dir $@) && \
- $(INKSCAPE) --export-width=32
+ $(RSVG_CONVERT) --format=png --width=32 $< > $@
%/favicon-64x64.png: %/favicon.svg
mkdir -p $(dir $@) && \
- $(INKSCAPE) --export-width=64
+ $(RSVG_CONVERT) --format=png --width=64 $< > $@
%/favicon-128x128.png: %/favicon.svg
mkdir -p $(dir $@) && \
- $(INKSCAPE) --export-width=128
+ $(RSVG_CONVERT) --format=png --width=128 $< > $@
%/favicon-256x256.png: %/favicon.svg
mkdir -p $(dir $@) && \
- $(INKSCAPE) --export-width=256
+ $(RSVG_CONVERT) --format=png --width=256 $< > $@
# This is like the favicon but in 180x180px
%/apple-touch-icon.png: %/favicon.svg
mkdir -p $(dir $@) && \
- $(INKSCAPE) --export-width=180
+ $(RSVG_CONVERT) --format=png --width=180 $< > $@
# Convert the logo to monochome only
%-monochrome.svg: %.svg