blob: 514f73795eb8a89d1b22d7b0ba74ceba4d8e435c (
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
|
--- configure.ac 2009-02-26 04:06:20.000000000 +0100
+++ configure.ac.patched 2016-01-30 11:24:14.906672000 +0100
@@ -69,7 +69,7 @@
fi
fi
-# Check for rsvg or ksvgtopng for creating large scale bitmaps from svg
+# Check for imagemagick for creating large scale bitmaps from svg
AC_ARG_ENABLE(png-creation,
AC_HELP_STRING([--enable-png-creation],
[enable creating png images from svg [default=disabled]]),
@@ -79,17 +79,13 @@
SVGCONVERT=""
AC_MSG_CHECKING([SVG to PNG conversion method])
if test "x$enable_large_bitmaps" = "xyes"; then
- PKG_CHECK_EXISTS([librsvg-2.0 >= 2.12.3],
+ PKG_CHECK_EXISTS([imagemagick],
[enable_large_bitmaps=yes], [enable_large_bitmaps=no])
- if test "x$enable_large_bitmaps" = "xyes"; then
- svgconvert_prog="rsvg"
- else
- svgconvert_prog="ksvgtopng"
- fi
+ svgconvert_prog="convert"
AC_MSG_RESULT([$svgconvert_prog])
AC_PATH_PROG(SVGCONVERT, $svgconvert_prog)
if test -z "$SVGCONVERT"; then
- AC_MSG_ERROR([You need librsvg >= 2.12.3 or ksvgtopng installed to create large scale bitmaps])
+ AC_MSG_ERROR([You need imagemagick installed to create large scale bitmaps])
else
enable_large_bitmaps=yes
fi
--- svg2png.sh.in 2007-02-16 21:04:29.000000000 +0100
+++ svg2png.sh.in.patched 2016-01-30 11:30:53.446678000 +0100
@@ -9,12 +9,9 @@
ICONFILE=`basename ${3}`
ICONNAME=`echo ${ICONFILE} | sed -e "s/.svg//"`
-if test `basename $SVGCONVERT` = "rsvg"; then
- OPTIONS="-w ${1} -h ${1}"
-else
- OPTIONS="${1} ${1}"
-fi
+OPTIONS="-background none"
+OUTPUT="-resize ${1}x${1}"
-echo "${SVGCONVERT} ${OPTIONS} ${3} ${2}/${ICONNAME}.png"
-${SVGCONVERT} ${OPTIONS} ${3} ${2}/${ICONNAME}.png
+echo "${SVGCONVERT} ${OPTIONS} ${3} ${OUTPUT} ${2}/${ICONNAME}.png"
+${SVGCONVERT} ${OPTIONS} ${3} ${OUTPUT} ${2}/${ICONNAME}.png
|