summaryrefslogtreecommitdiffstats
path: root/stylesheet-images/Makefile
blob: a8082c8b04524bb1a39a2c1f9c662609c34de3a0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
########################################################################
# Render SVG callouts into PNG
########################################################################
.SUFFIXES:
.SUFFIXES: .eps .png .svg

CALLSIZE	=16

# Need the "librsvg2" RPM for this
%.png:	%.svg
	rsvg -f png -h ${CALLSIZE} -w ${CALLSIZE} $< $@

# Need the "ImageMagick" RPM for this
%.eps:	%.png
	convert $< $@

NCALLOUTS	=15
CALLSVG	:=$(foreach n,$(shell seq 1 ${NCALLOUTS}),${n}.svg)
CALLPNG	=${CALLSVG:.svg=.png}
CALLEPS	=${CALLSVG:.svg=.eps}

all::	${CALLPNG} ${CALLEPS}

${CALLSVG}:: Makefile callout.svg
	sed -e "s/XX/$(basename $@ .svg)/g" callout.svg >$@

clean::
	${RM} ${CALLSVG}

distclean:: clean
	${RM} ${CALLPNG} ${CALLEPS}