1 |
dilfridge 14/05/24 00:07:15 |
2 |
|
3 |
Added: inkscape-0.48.4-poppler26.patch |
4 |
Log: |
5 |
Fix build with poppler-0.26, bug 509280 |
6 |
|
7 |
(Portage version: 2.2.10/cvs/Linux x86_64, signed Manifest commit with key EBE6A336BE19039C!) |
8 |
|
9 |
Revision Changes Path |
10 |
1.1 media-gfx/inkscape/files/inkscape-0.48.4-poppler26.patch |
11 |
|
12 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-gfx/inkscape/files/inkscape-0.48.4-poppler26.patch?rev=1.1&view=markup |
13 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-gfx/inkscape/files/inkscape-0.48.4-poppler26.patch?rev=1.1&content-type=text/plain |
14 |
|
15 |
Index: inkscape-0.48.4-poppler26.patch |
16 |
=================================================================== |
17 |
diff -ruN inkscape-0.48.4.orig/src/extension/internal/pdfinput/pdf-parser.cpp inkscape-0.48.4/src/extension/internal/pdfinput/pdf-parser.cpp |
18 |
--- inkscape-0.48.4.orig/src/extension/internal/pdfinput/pdf-parser.cpp 2012-12-13 18:00:46.726633000 +0100 |
19 |
+++ inkscape-0.48.4/src/extension/internal/pdfinput/pdf-parser.cpp 2014-05-07 22:50:03.891488716 +0200 |
20 |
@@ -56,6 +56,11 @@ |
21 |
#define M_PI 3.14159265358979323846 |
22 |
#endif |
23 |
|
24 |
+#include "poppler-features.h" |
25 |
+#if POPPLER_CHECK_VERSION(0, 26, 0) |
26 |
+#define POPPLER_26 |
27 |
+#endif |
28 |
+ |
29 |
//------------------------------------------------------------------------ |
30 |
// constants |
31 |
//------------------------------------------------------------------------ |
32 |
@@ -861,8 +866,12 @@ |
33 |
isolated = knockout = gFalse; |
34 |
if (!obj4.dictLookup(const_cast<char*>("CS"), &obj5)->isNull()) { |
35 |
#if defined(POPPLER_NEW_COLOR_SPACE_API) || defined(POPPLER_NEW_ERRORAPI) |
36 |
+#ifndef POPPLER_26 |
37 |
blendingColorSpace = GfxColorSpace::parse(&obj5, NULL); |
38 |
#else |
39 |
+ blendingColorSpace = GfxColorSpace::parse(&obj5, NULL, NULL); |
40 |
+#endif |
41 |
+#else |
42 |
blendingColorSpace = GfxColorSpace::parse(&obj5); |
43 |
#endif |
44 |
} |
45 |
@@ -1085,9 +1094,17 @@ |
46 |
res->lookupColorSpace(args[0].getName(), &obj); |
47 |
#if defined(POPPLER_NEW_COLOR_SPACE_API) || defined(POPPLER_NEW_ERRORAPI) |
48 |
if (obj.isNull()) { |
49 |
+#ifndef POPPLER_26 |
50 |
colorSpace = GfxColorSpace::parse(&args[0], NULL); |
51 |
+#else |
52 |
+ colorSpace = GfxColorSpace::parse(&args[0], NULL, NULL); |
53 |
+#endif |
54 |
} else { |
55 |
+#ifndef POPPLER_26 |
56 |
colorSpace = GfxColorSpace::parse(&obj, NULL); |
57 |
+#else |
58 |
+ colorSpace = GfxColorSpace::parse(&obj, NULL, NULL); |
59 |
+#endif |
60 |
} |
61 |
#else |
62 |
if (obj.isNull()) { |
63 |
@@ -1120,9 +1137,17 @@ |
64 |
res->lookupColorSpace(args[0].getName(), &obj); |
65 |
#if defined(POPPLER_NEW_COLOR_SPACE_API) || defined(POPPLER_NEW_ERRORAPI) |
66 |
if (obj.isNull()) { |
67 |
+#ifndef POPPLER_26 |
68 |
colorSpace = GfxColorSpace::parse(&args[0], NULL); |
69 |
+#else |
70 |
+ colorSpace = GfxColorSpace::parse(&args[0], NULL, NULL); |
71 |
+#endif |
72 |
} else { |
73 |
+#ifndef POPPLER_26 |
74 |
colorSpace = GfxColorSpace::parse(&obj, NULL); |
75 |
+#else |
76 |
+ colorSpace = GfxColorSpace::parse(&obj, NULL, NULL); |
77 |
+#endif |
78 |
} |
79 |
#else |
80 |
if (obj.isNull()) { |
81 |
@@ -1213,7 +1238,11 @@ |
82 |
} |
83 |
#if defined(POPPLER_NEW_COLOR_SPACE_API) || defined(POPPLER_NEW_ERRORAPI) |
84 |
if (args[numArgs-1].isName() && |
85 |
+#ifndef POPPLER_26 |
86 |
(pattern = res->lookupPattern(args[numArgs-1].getName(), NULL))) { |
87 |
+#else |
88 |
+ (pattern = res->lookupPattern(args[numArgs-1].getName(), NULL, NULL))) { |
89 |
+#endif |
90 |
state->setFillPattern(pattern); |
91 |
builder->updateStyle(state); |
92 |
} |
93 |
@@ -1273,7 +1302,11 @@ |
94 |
} |
95 |
#if defined(POPPLER_NEW_COLOR_SPACE_API) || defined(POPPLER_NEW_ERRORAPI) |
96 |
if (args[numArgs-1].isName() && |
97 |
+#ifndef POPPLER_26 |
98 |
(pattern = res->lookupPattern(args[numArgs-1].getName(), NULL))) { |
99 |
+#else |
100 |
+ (pattern = res->lookupPattern(args[numArgs-1].getName(), NULL, NULL))) { |
101 |
+#endif |
102 |
state->setStrokePattern(pattern); |
103 |
builder->updateStyle(state); |
104 |
} |
105 |
@@ -1711,7 +1744,11 @@ |
106 |
GBool savedState = gFalse; |
107 |
|
108 |
#if defined(POPPLER_NEW_COLOR_SPACE_API) || defined(POPPLER_NEW_ERRORAPI) |
109 |
+#ifndef POPPLER_26 |
110 |
if (!(shading = res->lookupShading(args[0].getName(), NULL))) { |
111 |
+#else |
112 |
+ if (!(shading = res->lookupShading(args[0].getName(), NULL, NULL))) { |
113 |
+#endif |
114 |
return; |
115 |
} |
116 |
#else |
117 |
@@ -2727,8 +2764,12 @@ |
118 |
} |
119 |
if (!obj1.isNull()) { |
120 |
#if defined(POPPLER_NEW_COLOR_SPACE_API) || defined(POPPLER_NEW_ERRORAPI) |
121 |
+#ifndef POPPLER_26 |
122 |
colorSpace = GfxColorSpace::parse(&obj1, NULL); |
123 |
#else |
124 |
+ colorSpace = GfxColorSpace::parse(&obj1, NULL, NULL); |
125 |
+#endif |
126 |
+#else |
127 |
colorSpace = GfxColorSpace::parse(&obj1); |
128 |
#endif |
129 |
} else if (csMode == streamCSDeviceGray) { |
130 |
@@ -2816,8 +2857,12 @@ |
131 |
} |
132 |
} |
133 |
#if defined(POPPLER_NEW_COLOR_SPACE_API) || defined(POPPLER_NEW_ERRORAPI) |
134 |
+#ifndef POPPLER_26 |
135 |
maskColorSpace = GfxColorSpace::parse(&obj1, NULL); |
136 |
#else |
137 |
+ maskColorSpace = GfxColorSpace::parse(&obj1, NULL, NULL); |
138 |
+#endif |
139 |
+#else |
140 |
maskColorSpace = GfxColorSpace::parse(&obj1); |
141 |
#endif |
142 |
obj1.free(); |
143 |
@@ -3007,8 +3052,12 @@ |
144 |
transpGroup = gTrue; |
145 |
if (!obj1.dictLookup(const_cast<char*>("CS"), &obj3)->isNull()) { |
146 |
#if defined(POPPLER_NEW_COLOR_SPACE_API) || defined(POPPLER_NEW_ERRORAPI) |
147 |
+#ifndef POPPLER_26 |
148 |
blendingColorSpace = GfxColorSpace::parse(&obj3, NULL); |
149 |
#else |
150 |
+ blendingColorSpace = GfxColorSpace::parse(&obj3, NULL, NULL); |
151 |
+#endif |
152 |
+#else |
153 |
blendingColorSpace = GfxColorSpace::parse(&obj3); |
154 |
#endif |
155 |
} |