aboutsummaryrefslogtreecommitdiffstats
path: root/graphics/inkscape
diff options
context:
space:
mode:
authorkwm <kwm@FreeBSD.org>2015-02-03 20:28:23 +0800
committerkwm <kwm@FreeBSD.org>2015-02-03 20:28:23 +0800
commitd9de6d533a2cc9890bb9a2a360d02bddf2efad6b (patch)
tree0d8165d979353f6e1f073311946757ff341c7c3d /graphics/inkscape
parentdd49cb10f9d7dcd03cc2d577bc195b50191f9477 (diff)
downloadfreebsd-ports-gnome-d9de6d533a2cc9890bb9a2a360d02bddf2efad6b.tar.gz
freebsd-ports-gnome-d9de6d533a2cc9890bb9a2a360d02bddf2efad6b.tar.zst
freebsd-ports-gnome-d9de6d533a2cc9890bb9a2a360d02bddf2efad6b.zip
Update poppler to 0.30.0 [1].
Make sure we use openjpeg1 in poppler, while openjpeg2 support was added there still bugs in openjpeg2 that need to be fixed. Add patches to inkscape for API changes in poppler 0.29.0 [2]. PR: 196599 [1] Submitted by: olivierd@ [1] Exp-run by: antoine@ Obtained from: upstream [2]
Diffstat (limited to 'graphics/inkscape')
-rw-r--r--graphics/inkscape/Makefile2
-rw-r--r--graphics/inkscape/files/configure.ac14
-rw-r--r--graphics/inkscape/files/patch-config.h.in12
-rw-r--r--graphics/inkscape/files/patch-configure121
-rw-r--r--graphics/inkscape/files/patch-src_extension_internal_pdfinput_pdf-parser.cpp83
5 files changed, 228 insertions, 4 deletions
diff --git a/graphics/inkscape/Makefile b/graphics/inkscape/Makefile
index 77a906ddee8a..5ef3296650d1 100644
--- a/graphics/inkscape/Makefile
+++ b/graphics/inkscape/Makefile
@@ -3,7 +3,7 @@
PORTNAME= inkscape
PORTVERSION= 0.48.5
-PORTREVISION= 3
+PORTREVISION= 4
CATEGORIES= graphics gnome
MASTER_SITES= SF
MASTER_SITE_SUBDIR=${PORTNAME:tl}/${PORTNAME:tl}/${PORTVERSION}
diff --git a/graphics/inkscape/files/configure.ac b/graphics/inkscape/files/configure.ac
new file mode 100644
index 000000000000..c19d64e60866
--- /dev/null
+++ b/graphics/inkscape/files/configure.ac
@@ -0,0 +1,14 @@
+--- configure.ac.orig 2015-01-29 19:58:01.271153231 +0100
++++ configure.ac 2015-01-29 19:58:25.237151226 +0100
+@@ -593,6 +593,11 @@
+ AC_DEFINE(POPPLER_EVEN_NEWER_COLOR_SPACE_API, 1, [Use even newer color space API from Poppler >= 0.26.0])
+ fi
+
++PKG_CHECK_MODULES(POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API, poppler >= 0.29.0, popplernewernewcolorspaceapi=yes, popplernewernewcolorspaceapi=no)
++if test "x$popplernewernewcolorspaceapi" = "xyes"; then
++ AC_DEFINE(POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API, 1, [Use even newer new color space API from Poppler >= 0.29.0])
++fi
++
+ # Poppler's b604a008 commit changes this
+ AC_MSG_CHECKING([whether Poppler's GfxPatch no longer uses GfxColor])
+ popplergfxcolor="no"
diff --git a/graphics/inkscape/files/patch-config.h.in b/graphics/inkscape/files/patch-config.h.in
new file mode 100644
index 000000000000..436063801eec
--- /dev/null
+++ b/graphics/inkscape/files/patch-config.h.in
@@ -0,0 +1,12 @@
+--- config.h.in.orig 2015-01-29 20:28:40.068026139 +0100
++++ config.h.in 2015-01-29 20:31:07.000000000 +0100
+@@ -246,6 +246,9 @@
+ /* Use even newer color space API from Poppler >= 0.26.0 */
+ #undef POPPLER_EVEN_NEWER_COLOR_SPACE_API
+
++/* Use even newer new color space API from Poppler >= 0.29.0 */
++#undef POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API
++
+ /* Use color space API from Poppler >= 0.12.2 */
+ #undef POPPLER_NEW_COLOR_SPACE_API
+
diff --git a/graphics/inkscape/files/patch-configure b/graphics/inkscape/files/patch-configure
index a775a80a07f9..7de3fd19b0cd 100644
--- a/graphics/inkscape/files/patch-configure
+++ b/graphics/inkscape/files/patch-configure
@@ -1,6 +1,37 @@
---- configure.orig 2014-10-20 01:29:05.836430783 +0200
-+++ configure 2014-10-20 01:29:05.872430406 +0200
-@@ -9046,10 +9046,11 @@
+--- configure.orig 2015-01-29 19:57:54.424153129 +0100
++++ configure 2015-01-29 20:00:37.112141976 +0100
+@@ -657,6 +657,8 @@
+ LIBWPG01_CFLAGS
+ INKBOARD_CFLAGS
+ INKBOARD_LIBS
++POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_LIBS
++POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_CFLAGS
+ POPPLER_EVEN_NEWER_COLOR_SPACE_API_LIBS
+ POPPLER_EVEN_NEWER_COLOR_SPACE_API_CFLAGS
+ POPPLER_NEWERRORAPI_LIBS
+@@ -914,6 +916,8 @@
+ POPPLER_NEWERRORAPI_LIBS
+ POPPLER_EVEN_NEWER_COLOR_SPACE_API_CFLAGS
+ POPPLER_EVEN_NEWER_COLOR_SPACE_API_LIBS
++POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_CFLAGS
++POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_LIBS
+ LIBWPG01_CFLAGS
+ LIBWPG01_LIBS
+ LIBWPG02_CFLAGS
+@@ -1630,6 +1634,12 @@
+ POPPLER_EVEN_NEWER_COLOR_SPACE_API_LIBS
+ linker flags for POPPLER_EVEN_NEWER_COLOR_SPACE_API, overriding
+ pkg-config
++ POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_CFLAGS
++ C compiler flags for POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API,
++ overriding pkg-config
++ POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_LIBS
++ linker flags for POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API,
++ overriding pkg-config
+ LIBWPG01_CFLAGS
+ C compiler flags for LIBWPG01, overriding pkg-config
+ LIBWPG01_LIBS
+@@ -9047,10 +9057,11 @@
#include <stdio.h>
extern unsigned GC_version;
int main(void){
@@ -16,3 +47,87 @@
}
_ACEOF
if ac_fn_cxx_try_run "$LINENO"; then :
+@@ -10561,6 +10572,83 @@
+
+ fi
+
++
++pkg_failed=no
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API" >&5
++$as_echo_n "checking for POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API... " >&6; }
++
++if test -n "$POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_CFLAGS"; then
++ pkg_cv_POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_CFLAGS="$POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_CFLAGS"
++ elif test -n "$PKG_CONFIG"; then
++ if test -n "$PKG_CONFIG" && \
++ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"poppler >= 0.29.0\""; } >&5
++ ($PKG_CONFIG --exists --print-errors "poppler >= 0.29.0") 2>&5
++ ac_status=$?
++ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
++ test $ac_status = 0; }; then
++ pkg_cv_POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_CFLAGS=`$PKG_CONFIG --cflags "poppler >= 0.29.0" 2>/dev/null`
++ test "x$?" != "x0" && pkg_failed=yes
++else
++ pkg_failed=yes
++fi
++ else
++ pkg_failed=untried
++fi
++if test -n "$POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_LIBS"; then
++ pkg_cv_POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_LIBS="$POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_LIBS"
++ elif test -n "$PKG_CONFIG"; then
++ if test -n "$PKG_CONFIG" && \
++ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"poppler >= 0.29.0\""; } >&5
++ ($PKG_CONFIG --exists --print-errors "poppler >= 0.29.0") 2>&5
++ ac_status=$?
++ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
++ test $ac_status = 0; }; then
++ pkg_cv_POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_LIBS=`$PKG_CONFIG --libs "poppler >= 0.29.0" 2>/dev/null`
++ test "x$?" != "x0" && pkg_failed=yes
++else
++ pkg_failed=yes
++fi
++ else
++ pkg_failed=untried
++fi
++
++
++
++if test $pkg_failed = yes; then
++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
++$as_echo "no" >&6; }
++
++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
++ _pkg_short_errors_supported=yes
++else
++ _pkg_short_errors_supported=no
++fi
++ if test $_pkg_short_errors_supported = yes; then
++ POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "poppler >= 0.29.0" 2>&1`
++ else
++ POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "poppler >= 0.29.0" 2>&1`
++ fi
++ # Put the nasty error message in config.log where it belongs
++ echo "$POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_PKG_ERRORS" >&5
++
++ popplernewernewcolorspaceapi=no
++elif test $pkg_failed = untried; then
++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
++$as_echo "no" >&6; }
++ popplernewernewcolorspaceapi=no
++else
++ POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_CFLAGS=$pkg_cv_POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_CFLAGS
++ POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_LIBS=$pkg_cv_POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API_LIBS
++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
++$as_echo "yes" >&6; }
++ popplernewernewcolorspaceapi=yes
++fi
++if test "x$popplernewernewcolorspaceapi" = "xyes"; then
++
++$as_echo "#define POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API 1" >>confdefs.h
++
++fi
++
+ # Poppler's b604a008 commit changes this
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Poppler's GfxPatch no longer uses GfxColor" >&5
+ $as_echo_n "checking whether Poppler's GfxPatch no longer uses GfxColor... " >&6; }
diff --git a/graphics/inkscape/files/patch-src_extension_internal_pdfinput_pdf-parser.cpp b/graphics/inkscape/files/patch-src_extension_internal_pdfinput_pdf-parser.cpp
new file mode 100644
index 000000000000..ab74fc0e68e2
--- /dev/null
+++ b/graphics/inkscape/files/patch-src_extension_internal_pdfinput_pdf-parser.cpp
@@ -0,0 +1,83 @@
+=== modified file 'src/extension/internal/pdfinput/pdf-parser.cpp'
+--- src/extension/internal/pdfinput/pdf-parser.cpp 2014-06-03 15:44:09 +0000
++++ src/extension/internal/pdfinput/pdf-parser.cpp 2014-12-10 20:32:30 +0000
+@@ -860,7 +860,9 @@
+ blendingColorSpace = NULL;
+ isolated = knockout = gFalse;
+ if (!obj4.dictLookup(const_cast<char*>("CS"), &obj5)->isNull()) {
+-#if defined(POPPLER_EVEN_NEWER_COLOR_SPACE_API)
++#if defined(POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API)
++ blendingColorSpace = GfxColorSpace::parse(NULL, &obj5, NULL, NULL);
++#elif defined(POPPLER_EVEN_NEWER_COLOR_SPACE_API)
+ blendingColorSpace = GfxColorSpace::parse(&obj5, NULL, NULL);
+ #elif defined(POPPLER_NEW_COLOR_SPACE_API) || defined(POPPLER_NEW_ERRORAPI)
+ blendingColorSpace = GfxColorSpace::parse(&obj5, NULL);
+@@ -1085,7 +1087,13 @@
+
+ state->setFillPattern(NULL);
+ res->lookupColorSpace(args[0].getName(), &obj);
+-#if defined(POPPLER_EVEN_NEWER_COLOR_SPACE_API)
++#if defined(POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API)
++ if (obj.isNull()) {
++ colorSpace = GfxColorSpace::parse(NULL, &args[0], NULL, NULL);
++ } else {
++ colorSpace = GfxColorSpace::parse(NULL, &obj, NULL, NULL);
++ }
++#elif defined(POPPLER_EVEN_NEWER_COLOR_SPACE_API)
+ if (obj.isNull()) {
+ colorSpace = GfxColorSpace::parse(&args[0], NULL, NULL);
+ } else {
+@@ -1126,7 +1134,13 @@
+
+ state->setStrokePattern(NULL);
+ res->lookupColorSpace(args[0].getName(), &obj);
+-#if defined(POPPLER_EVEN_NEWER_COLOR_SPACE_API)
++#if defined(POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API)
++ if (obj.isNull()) {
++ colorSpace = GfxColorSpace::parse(NULL, &args[0], NULL, NULL);
++ } else {
++ colorSpace = GfxColorSpace::parse(NULL, &obj, NULL, NULL);
++ }
++#elif defined(POPPLER_EVEN_NEWER_COLOR_SPACE_API)
+ if (obj.isNull()) {
+ colorSpace = GfxColorSpace::parse(&args[0], NULL, NULL);
+ } else {
+@@ -2756,8 +2770,10 @@
+ }
+ }
+ if (!obj1.isNull()) {
+-#if defined(POPPLER_EVEN_NEWER_COLOR_SPACE_API)
+- colorSpace = GfxColorSpace::parse(&obj1, NULL, NULL);
++#if defined(POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API)
++ colorSpace = GfxColorSpace::parse(NULL, &obj1, NULL, NULL);
++#elif defined(POPPLER_EVEN_NEWER_COLOR_SPACE_API)
++ colorSpace = GfxColorSpace::parse(&obj1, NULL, NULL);
+ #elif defined(POPPLER_NEW_COLOR_SPACE_API) || defined(POPPLER_NEW_ERRORAPI)
+ colorSpace = GfxColorSpace::parse(&obj1, NULL);
+ #else
+@@ -2847,8 +2863,10 @@
+ obj2.free();
+ }
+ }
+-#if defined(POPPLER_EVEN_NEWER_COLOR_SPACE_API)
+- GfxColorSpace *maskColorSpace = GfxColorSpace::parse(&obj1, NULL, NULL);
++#if defined(POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API)
++ GfxColorSpace *maskColorSpace = GfxColorSpace::parse(NULL, &obj1, NULL, NULL);
++#elif defined(POPPLER_EVEN_NEWER_COLOR_SPACE_API)
++ GfxColorSpace *maskColorSpace = GfxColorSpace::parse(&obj1, NULL, NULL);
+ #elif defined(POPPLER_NEW_COLOR_SPACE_API) || defined(POPPLER_NEW_ERRORAPI)
+ maskColorSpace = GfxColorSpace::parse(&obj1, NULL);
+ #else
+@@ -3040,7 +3058,9 @@
+ if (obj1.dictLookup(const_cast<char*>("S"), &obj2)->isName(const_cast<char*>("Transparency"))) {
+ transpGroup = gTrue;
+ if (!obj1.dictLookup(const_cast<char*>("CS"), &obj3)->isNull()) {
+-#if defined(POPPLER_EVEN_NEWER_COLOR_SPACE_API)
++#if defined(POPPLER_EVEN_NEWER_NEW_COLOR_SPACE_API)
++ blendingColorSpace = GfxColorSpace::parse(NULL, &obj3, NULL, NULL);
++#elif defined(POPPLER_EVEN_NEWER_COLOR_SPACE_API)
+ blendingColorSpace = GfxColorSpace::parse(&obj3, NULL, NULL);
+ #elif defined(POPPLER_NEW_COLOR_SPACE_API) || defined(POPPLER_NEW_ERRORAPI)
+ blendingColorSpace = GfxColorSpace::parse(&obj3, NULL);
+
+