From ffa4f6b72089747afc84cd316bb0dca20b5dbd33 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felix=20Bu=CC=88nemann?= Date: Fri, 27 May 2016 00:55:32 +0200 Subject: [PATCH 1/3] Lower librsvg version requirement to 2.34 This is the first version that works properly with gtk3. Lowering the requirement enables SVG support on older Linux distributions like Ubuntu Precise LTS or Debian Wheezy. --- configure.ac | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/configure.ac b/configure.ac index ca07f495..562c297b 100644 --- a/configure.ac +++ b/configure.ac @@ -605,12 +605,12 @@ AC_ARG_WITH([rsvg], AS_HELP_STRING([--without-rsvg], [build without rsvg (default: test)])) if test x"$with_rsvg" != x"no"; then - PKG_CHECK_MODULES(RSVG, [librsvg-2.0 >= 2.40 cairo >= 1.2], - [AC_DEFINE(HAVE_RSVG,1,[define if you have librsvg-2.0 >= 2.40.0 and cairo >= 1.2 installed.]) + PKG_CHECK_MODULES(RSVG, [librsvg-2.0 >= 2.34 cairo >= 1.2], + [AC_DEFINE(HAVE_RSVG,1,[define if you have librsvg-2.0 >= 2.34.0 and cairo >= 1.2 installed.]) with_rsvg=yes PACKAGES_USED="$PACKAGES_USED librsvg-2.0 cairo" ], - [AC_MSG_WARN([librsvg-2.0 >= 2.40.0 or cairo >= 1.2 not found; disabling SVG load via rsvg]) + [AC_MSG_WARN([librsvg-2.0 >= 2.34.0 or cairo >= 1.2 not found; disabling SVG load via rsvg]) with_rsvg=no ] ) @@ -1034,7 +1034,7 @@ file import with matio: $with_matio PDF import with poppler-glib: $with_poppler (requires poppler-glib 0.16.0 or later) SVG import with librsvg-2.0: $with_rsvg - (requires librsvg-2.0 2.40.0 or later) + (requires librsvg-2.0 2.34.0 or later) file import with cfitsio: $with_cfitsio file import/export with libwebp: $with_libwebp (requires libwebp-0.1.3 or later) From f9dc33c8f2cf6dcc68cdb768dfa3e2288e42f30e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felix=20Bu=CC=88nemann?= Date: Fri, 27 May 2016 00:57:45 +0200 Subject: [PATCH 2/3] Test svgload in make check and on Travis CI --- .travis.yml | 1 + test/images/blankpage.pdf | 0 test/images/blankpage.svg | 3 +++ test/test_formats.sh | 8 ++++++++ 4 files changed, 12 insertions(+) mode change 100755 => 100644 test/images/blankpage.pdf create mode 100644 test/images/blankpage.svg diff --git a/.travis.yml b/.travis.yml index 3852c822..e10ef52c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -8,6 +8,7 @@ before_install: - sudo apt-get install swig libmagick++-dev bc - sudo apt-get install libcfitsio3-dev libgsl0-dev libmatio-dev - sudo apt-get install liborc-0.4-dev liblcms2-dev libpoppler-glib-dev + - sudo apt-get install librsvg2-dev before_script: - ./bootstrap.sh - ./configure diff --git a/test/images/blankpage.pdf b/test/images/blankpage.pdf old mode 100755 new mode 100644 diff --git a/test/images/blankpage.svg b/test/images/blankpage.svg new file mode 100644 index 00000000..b0365ff7 --- /dev/null +++ b/test/images/blankpage.svg @@ -0,0 +1,3 @@ + + + diff --git a/test/test_formats.sh b/test/test_formats.sh index c44ce02e..631b4fbc 100755 --- a/test/test_formats.sh +++ b/test/test_formats.sh @@ -11,6 +11,10 @@ poppler=$test_images/blankpage.pdf poppler_ref=$test_images/blankpage.png +# rsvg / svgload reference image +rsvg=$test_images/blankpage.svg +rsvg_ref=$test_images/blankpage.png + # the matlab image and reference image matlab=$test_images/sample.mat matlab_ref=$test_images/sample.png @@ -222,6 +226,10 @@ if test_supported pdfload; then test_loader $poppler_ref $poppler pdfload fi +if test_supported svgload; then + test_loader $rsvg_ref $rsvg svgload +fi + if test_supported matload; then test_loader $matlab_ref $matlab matlab fi From fdeb1b3b12fd5b84e3b9a83639e9f619382a7052 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felix=20Bu=CC=88nemann?= Date: Fri, 27 May 2016 01:25:35 +0200 Subject: [PATCH 3/3] Test gifload in make check and on Travis CI --- .travis.yml | 2 +- test/images/trans-x.png | Bin 0 -> 436 bytes test/test_formats.sh | 8 ++++++++ 3 files changed, 9 insertions(+), 1 deletion(-) create mode 100644 test/images/trans-x.png diff --git a/.travis.yml b/.travis.yml index e10ef52c..cc454de8 100644 --- a/.travis.yml +++ b/.travis.yml @@ -8,7 +8,7 @@ before_install: - sudo apt-get install swig libmagick++-dev bc - sudo apt-get install libcfitsio3-dev libgsl0-dev libmatio-dev - sudo apt-get install liborc-0.4-dev liblcms2-dev libpoppler-glib-dev - - sudo apt-get install librsvg2-dev + - sudo apt-get install librsvg2-dev libgif-dev before_script: - ./bootstrap.sh - ./configure diff --git a/test/images/trans-x.png b/test/images/trans-x.png new file mode 100644 index 0000000000000000000000000000000000000000..627f80be3ede672528900a4203fbf67cb72545c0 GIT binary patch literal 436 zcmeAS@N?(olHy`uVBq!ia0vp^DImSw*Sy6T_y`;W%2yCcICPi$GeaS_+{HBaiNT)cgD@r>+iI>mt@GbX6czq7!| zaFUhqr#$b=fm%mguX0Lm{i+gb^xB-BC1n!=`V?O9ScA>3?3EQnqk zb zlKo=zZad#Qpk}F-jiK?c1j4xr>q`l--~Y) z=I<$r_Bpvm;rW{C`B~@R>#qIe&3AqF_OEY$q`%f%YkT!gw3s;yBRsGe7+$>PuZYtO TGIZE(021|d^>bP0l+XkKE9bp* literal 0 HcmV?d00001 diff --git a/test/test_formats.sh b/test/test_formats.sh index 631b4fbc..130f0dcb 100755 --- a/test/test_formats.sh +++ b/test/test_formats.sh @@ -15,6 +15,10 @@ poppler_ref=$test_images/blankpage.png rsvg=$test_images/blankpage.svg rsvg_ref=$test_images/blankpage.png +# giflib / gifload reference image +giflib=$test_images/trans-x.gif +giflib_ref=$test_images/trans-x.png + # the matlab image and reference image matlab=$test_images/sample.mat matlab_ref=$test_images/sample.png @@ -230,6 +234,10 @@ if test_supported svgload; then test_loader $rsvg_ref $rsvg svgload fi +if test_supported gifload; then + test_loader $giflib_ref $giflib gifload +fi + if test_supported matload; then test_loader $matlab_ref $matlab matlab fi