Saturday, December 29, 2018

fix editors/libreoffice with poppler-0.72.0

Hi,

the diff below would fix the build of libreoffice after the update
of poppler to 0.72.0
(https://marc.info/?l=openbsd-ports&m=154594206203586&w=2).

ok (after the commit of the poppler update in a few days)?

Ciao,
Kili

Index: patches/patch-sdext_source_pdfimport_xpdfwrapper_pdfioutdev_gpl_cxx
===================================================================
RCS file: patches/patch-sdext_source_pdfimport_xpdfwrapper_pdfioutdev_gpl_cxx
diff -N patches/patch-sdext_source_pdfimport_xpdfwrapper_pdfioutdev_gpl_cxx
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-sdext_source_pdfimport_xpdfwrapper_pdfioutdev_gpl_cxx 29 Dec 2018 19:17:53 -0000
@@ -0,0 +1,106 @@
+$OpenBSD$
+
+Fix with newer poppler. From archlinux.
+
+Index: sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx
+--- sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx.orig
++++ sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx
+@@ -514,7 +514,7 @@ void PDFOutDev::printPath( GfxPath* pPath )
+ PDFOutDev::PDFOutDev( PDFDoc* pDoc ) :
+ m_pDoc( pDoc ),
+ m_aFontMap(),
+- m_pUtf8Map( new UnicodeMap("UTF-8", gTrue, &mapUTF8) ),
++ m_pUtf8Map( new UnicodeMap("UTF-8", true, &mapUTF8) ),
+ m_bSkipImages(false)
+ {
+ }
+@@ -555,7 +555,7 @@ void PDFOutDev::processLink(Link* link, Catalog*)
+ LinkAction* pAction = link->getAction();
+ if (pAction && pAction->getKind() == actionURI)
+ {
+- const char* pURI = static_cast<LinkURI*>(pAction)->getURI()->getCString();
++ const char* pURI = static_cast<LinkURI*>(pAction)->getURI()->c_str();
+
+ std::vector<char> aEsc( lcl_escapeLineFeeds(pURI) );
+
+@@ -578,7 +578,11 @@ void PDFOutDev::restoreState(GfxState*)
+ printf( "restoreState\n" );
+ }
+
++#if POPPLER_CHECK_VERSION(0, 70, 0)
++void PDFOutDev::setDefaultCTM(const double *pMat)
++#else
+ void PDFOutDev::setDefaultCTM(double *pMat)
++

No comments:

Post a Comment