Accepting request 1005011 from home:cgiboudeaux:branches:LibreOffice:Factory
Add the traditional poppler compatibility fix OBS-URL: https://build.opensuse.org/request/show/1005011 OBS-URL: https://build.opensuse.org/package/show/LibreOffice:Factory/libreoffice?expand=0&rev=1034
This commit is contained in:
parent
d6cc10cc1f
commit
bdb9d5cc0d
55
0001-Fix-build-with-Poppler-22.09.0.patch
Normal file
55
0001-Fix-build-with-Poppler-22.09.0.patch
Normal file
@ -0,0 +1,55 @@
|
|||||||
|
From b7d63694985bbb1cf86eb71769feadb28ce68c17 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Sam James <sam@gentoo.org>
|
||||||
|
Date: Fri, 2 Sep 2022 04:31:18 +0100
|
||||||
|
Subject: [PATCH] Fix build with Poppler 22.09.0
|
||||||
|
|
||||||
|
With Poppler 22.09.0, LO fails to build with:
|
||||||
|
```
|
||||||
|
/var/tmp/portage/app-office/libreoffice-7.3.5.2/work/libreoffice-7.3.5.2/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx:682:36: error: too many arguments to function call, expected single argument 'start', have 3 arguments
|
||||||
|
state->getLineDash(&dashArray, &arrayLen, &startOffset);
|
||||||
|
~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
/usr/include/poppler/GfxState.h:1506:32: note: 'getLineDash' declared here
|
||||||
|
const std::vector<double> &getLineDash(double *start)
|
||||||
|
^
|
||||||
|
1 error generated.
|
||||||
|
```
|
||||||
|
|
||||||
|
Poppler changed the getLineDash interface:
|
||||||
|
```
|
||||||
|
- void getLineDash(double **dash, int *length, double *start)
|
||||||
|
+ const std::vector<double> &getLineDash(double *start)
|
||||||
|
```
|
||||||
|
|
||||||
|
Signed-off-by: Sam James <sam@gentoo.org>
|
||||||
|
Change-Id: I29e18f20d7650a7fcac1bc8ab4aaa04aaa2ab8fb
|
||||||
|
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139249
|
||||||
|
Tested-by: Jenkins
|
||||||
|
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
|
||||||
|
---
|
||||||
|
sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx | 9 ++++++++-
|
||||||
|
1 file changed, 8 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx b/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx
|
||||||
|
index f12478cb2f4d..3ad139b65fa3 100644
|
||||||
|
--- a/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx
|
||||||
|
+++ b/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx
|
||||||
|
@@ -678,8 +678,15 @@ void PDFOutDev::updateLineDash(GfxState *state)
|
||||||
|
return;
|
||||||
|
assert(state);
|
||||||
|
|
||||||
|
- double* dashArray; int arrayLen; double startOffset;
|
||||||
|
+ int arrayLen; double startOffset;
|
||||||
|
+#if POPPLER_CHECK_VERSION(22, 9, 0)
|
||||||
|
+ const std::vector<double> &dash = state->getLineDash(&startOffset);
|
||||||
|
+ const double* dashArray = dash.data();
|
||||||
|
+ arrayLen = dash.size();
|
||||||
|
+#else
|
||||||
|
+ double* dashArray;
|
||||||
|
state->getLineDash(&dashArray, &arrayLen, &startOffset);
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
printf( "updateLineDash" );
|
||||||
|
if( arrayLen && dashArray )
|
||||||
|
--
|
||||||
|
2.37.3
|
||||||
|
|
@ -1,3 +1,9 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Sep 20 16:28:58 UTC 2022 - Christophe Giboudeaux <christophe@krop.fr>
|
||||||
|
|
||||||
|
- Add popper 22.09 compatibility fix:
|
||||||
|
* 0001-Fix-build-with-Poppler-22.09.0.patch
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Aug 31 07:45:42 UTC 2022 - Danilo Spinella <danilo.spinella@suse.com>
|
Wed Aug 31 07:45:42 UTC 2022 - Danilo Spinella <danilo.spinella@suse.com>
|
||||||
|
|
||||||
|
@ -96,6 +96,8 @@ Source2009: %{external_url}/dtoa-20180411.tgz
|
|||||||
# Skia is part of chromium and bundled everywhere as by google only way is monorepo way
|
# Skia is part of chromium and bundled everywhere as by google only way is monorepo way
|
||||||
Source2010: %{external_url}/skia-m103-b301ff025004c9cd82816c86c547588e6c24b466.tar.xz
|
Source2010: %{external_url}/skia-m103-b301ff025004c9cd82816c86c547588e6c24b466.tar.xz
|
||||||
Source2012: %{external_url}/libcmis-0.5.2.tar.xz
|
Source2012: %{external_url}/libcmis-0.5.2.tar.xz
|
||||||
|
# poppler 22.09 compatibility
|
||||||
|
Patch0: 0001-Fix-build-with-Poppler-22.09.0.patch
|
||||||
# change user config dir name from ~/.libreoffice/3 to ~/.libreoffice/3-suse
|
# change user config dir name from ~/.libreoffice/3 to ~/.libreoffice/3-suse
|
||||||
# to avoid BerkleyDB incompatibility with the plain build
|
# to avoid BerkleyDB incompatibility with the plain build
|
||||||
Patch1: scp2-user-config-suse.diff
|
Patch1: scp2-user-config-suse.diff
|
||||||
@ -1008,6 +1010,7 @@ Provides %{langname} translations and additional resources (help files, etc.) fo
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -b2 -b4
|
%setup -q -b2 -b4
|
||||||
|
%patch0 -p1
|
||||||
%if 0%{?suse_version} < 1500
|
%if 0%{?suse_version} < 1500
|
||||||
# The rename of the configdir is needed only on older than factory for compat
|
# The rename of the configdir is needed only on older than factory for compat
|
||||||
%patch1
|
%patch1
|
||||||
|
Loading…
x
Reference in New Issue
Block a user