Gentoo Archives: gentoo-commits

From: Sam James <sam@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: media-gfx/inkscape/files/
Date: Fri, 02 Sep 2022 05:52:13
Message-Id: 1662096733.8b48848a1b4238b6e3abb3e9b546014bc72d5c8e.sam@gentoo
1 commit: 8b48848a1b4238b6e3abb3e9b546014bc72d5c8e
2 Author: Sam James <sam <AT> gentoo <DOT> org>
3 AuthorDate: Fri Sep 2 05:26:16 2022 +0000
4 Commit: Sam James <sam <AT> gentoo <DOT> org>
5 CommitDate: Fri Sep 2 05:32:13 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8b48848a
7
8 media-gfx/inkscape: add link to upstream PR for poppler fix
9
10 Signed-off-by: Sam James <sam <AT> gentoo.org>
11
12 .../files/inkscape-1.2.1-poppler-22.09.0.patch | 38 ++++++++++++++++++++++
13 1 file changed, 38 insertions(+)
14
15 diff --git a/media-gfx/inkscape/files/inkscape-1.2.1-poppler-22.09.0.patch b/media-gfx/inkscape/files/inkscape-1.2.1-poppler-22.09.0.patch
16 index 2e5d3b4782f3..87583019d6e3 100644
17 --- a/media-gfx/inkscape/files/inkscape-1.2.1-poppler-22.09.0.patch
18 +++ b/media-gfx/inkscape/files/inkscape-1.2.1-poppler-22.09.0.patch
19 @@ -1,3 +1,41 @@
20 +https://gitlab.com/inkscape/inkscape/-/merge_requests/4719
21 +
22 +From dce083204c62f1185ad079fc124f7fb40a1d0bb6 Mon Sep 17 00:00:00 2001
23 +From: Sam James <sam@g.o>
24 +Date: Fri, 2 Sep 2022 06:21:28 +0100
25 +Subject: [PATCH] Fix build with Poppler 22.09.0
26 +MIME-Version: 1.0
27 +Content-Type: text/plain; charset=UTF-8
28 +Content-Transfer-Encoding: 8bit
29 +
30 +With Poppler 22.09.0, inkscape fails to build with:
31 +```
32 +/var/tmp/portage/media-gfx/inkscape-1.2.1/work/inkscape-1.2.1/src/extension/internal/pdfinput/svg-builder.cpp:394:23: error: no matching function for call to ‘GfxState::getLineDash(double**, int*, double*)’
33 + 394 | state->getLineDash(&dash_pattern, &dash_length, &dash_start);
34 + | ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
35 +In file included from /var/tmp/portage/media-gfx/inkscape-1.2.1/work/inkscape-1.2.1/src/extension/internal/pdfinput/svg-builder.cpp:44:
36 +/usr/include/poppler/GfxState.h:1506:32: note: candidate: ‘const std::vector<double>& GfxState::getLineDash(double*)’
37 + 1506 | const std::vector<double> &getLineDash(double *start)
38 + | ^~~~~~~~~~~
39 +[...]
40 +/var/tmp/portage/media-gfx/inkscape-1.2.1/work/inkscape-1.2.1/src/extension/internal/pdfinput/pdf-parser.cpp:700:21: error: no matching function for call to ‘GfxState::setLineDash(double*&, int&, double)’
41 + 700 | state->setLineDash(dash, length, args[1].getNum());
42 + | ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
43 +```
44 +
45 +Poppler changed the getLineDash interface:
46 +```
47 +- void getLineDash(double **dash, int *length, double *start)
48 ++ const std::vector<double> &getLineDash(double *start)
49 +```
50 +
51 +... and the setLineDash interface:
52 +````
53 +- void setLineDash(double *dash, int length, double start);
54 ++ void setLineDash(std::vector<double> &&dash, double start);
55 +```
56 +
57 +Signed-off-by: Sam James <sam@g.o>
58 --- a/src/extension/internal/pdfinput/pdf-parser.cpp
59 +++ b/src/extension/internal/pdfinput/pdf-parser.cpp
60 @@ -697,7 +697,11 @@ void PdfParser::opSetDash(Object args[], int /*numArgs*/)