From 82472916443788b967f8624a069cdeabf1e4c2ab Mon Sep 17 00:00:00 2001 From: Johannes Date: Thu, 8 Nov 2018 20:40:10 +0100 Subject: [PATCH] libgdal: fix build --- srcpkgs/libgdal/patches/poppler-069.patch | 51 +++++++++++++++++++++++ 1 file changed, 51 insertions(+) diff --git a/srcpkgs/libgdal/patches/poppler-069.patch b/srcpkgs/libgdal/patches/poppler-069.patch index 993a10ccb78..683175439be 100644 --- a/srcpkgs/libgdal/patches/poppler-069.patch +++ b/srcpkgs/libgdal/patches/poppler-069.patch @@ -300,3 +300,54 @@ index a3b88583425..c9ca28d3cd9 100644 # Uncomment for PDF support +--- frmts/pdf/pdfdataset.cpp.orig 2018-11-08 20:25:24.398021193 +0100 ++++ frmts/pdf/pdfdataset.cpp 2018-11-08 20:35:15.305346284 +0100 +@@ -2599,7 +2599,7 @@ + #else + int nPos, + #endif +- char *pszMsg) ++ const char *pszMsg) + { + CPLString osError; + +@@ -4442,7 +4442,7 @@ + #ifdef HAVE_POPPLER + if (bUseLib.test(PDFLIB_POPPLER)) + { +- PDFRectangle* psMediaBox = poPagePoppler->getMediaBox(); ++ const PDFRectangle* psMediaBox = poPagePoppler->getMediaBox(); + dfX1 = psMediaBox->x1; + dfY1 = psMediaBox->y1; + dfX2 = psMediaBox->x2; +@@ -4454,7 +4454,7 @@ + if (bUseLib.test(PDFLIB_PODOFO)) + { + CPLAssert(poPagePodofo); +- PoDoFo::PdfRect oMediaBox = poPagePodofo->GetMediaBox(); ++ const PoDoFo::PdfRect oMediaBox = poPagePodofo->GetMediaBox(); + dfX1 = oMediaBox.GetLeft(); + dfY1 = oMediaBox.GetBottom(); + dfX2 = dfX1 + oMediaBox.GetWidth(); +@@ -4780,7 +4780,7 @@ + GooString* poMetadata = poCatalogPoppler->readMetadata(); + if (poMetadata) + { +- char* pszContent = poMetadata->getCString(); ++ const char* pszContent = poMetadata->getCString(); + if (pszContent != nullptr && + STARTS_WITH(pszContent, "SetMetadata(apszMDList, "xml:XMP"); ++ poDS->SetMetadata((char **) apszMDList, "xml:XMP"); + } + delete poMetadata; + }