diff options
Diffstat (limited to 'sci-libs/gdal')
-rw-r--r-- | sci-libs/gdal/Manifest | 6 | ||||
-rw-r--r-- | sci-libs/gdal/files/gdal-2.4.1-poppler-0.75.patch | 148 | ||||
-rw-r--r-- | sci-libs/gdal/files/gdal-2.4.1-poppler-0.76.patch | 24 | ||||
-rw-r--r-- | sci-libs/gdal/gdal-2.4.0.ebuild | 2 | ||||
-rw-r--r-- | sci-libs/gdal/gdal-2.4.1.ebuild | 3 |
5 files changed, 179 insertions, 4 deletions
diff --git a/sci-libs/gdal/Manifest b/sci-libs/gdal/Manifest index d568a4c6b770..cf98462cae1b 100644 --- a/sci-libs/gdal/Manifest +++ b/sci-libs/gdal/Manifest @@ -5,10 +5,12 @@ AUX gdal-2.3.1-poppler-0.69.0.patch 12775 BLAKE2B 27fe38cb5db58961e1f9f4aef9eddb AUX gdal-2.3.1-poppler-0.71.0.patch 2770 BLAKE2B d856ebd2cc1077b39303ca0300ff5a27d1d9981c4f557bb935a0a2ddf7372ef3ae25b59c8f87a103eaf8be0eb467741b1191032889efb5f98a8bb09be1254ab5 SHA512 9c8fc013b191fc579517389928c2d0c4c2f769f188b26fa86b192dc6e7223c799f579095d0765ffe2c6f7158a661b384cb36e92e7bc8c1d5af236d24fe41281d AUX gdal-2.3.1-poppler-0.72.0.patch 2377 BLAKE2B c70dbfba879ecba9956b27e56ffe6fcbb076b9f6ed127eedc201c8d47cf527109374e98e2c31107f9ff14dace67556bffeff8651ae01161f2cb9e78732585846 SHA512 985a44492c585c1c8066feb7810b135535ccc87abf86996f64806e53952e7dd96c02649e072a1329aefab80c03d2d6069c829d36c4ea1471493cfb3af26eb69e AUX gdal-2.3.1-poppler-0.73.0.patch 906 BLAKE2B c71bf66068f19e80f38907d3f5ffd24e73ae4be99f720cc852ba8aad2f6999a020d59e068ed8a173c6f84e97471c1f6937f82d2519a166282216995cb8db69bb SHA512 0e846ec7c5ddf44144949018ae70063df1043f9dc2730bb189e794ffb40bd91869bd6f5939bd40fc88b18fb53f20151e286610a8db6e9292ba1c5ccc4065148f +AUX gdal-2.4.1-poppler-0.75.patch 5452 BLAKE2B 7cb3b1e84f2f1ff91af49cb4292047f055aeff5a45c8f0d4c440c99d2ab746d32500f11c040f0eaba72b8da9122ab5fc3b5d50dc082c60281354652ab65fff9f SHA512 7482a8a160f514c31c11d101e1f8a2c32dcc862b3c7bc76ac11712bca7c3088975b4fefae33a6d68a847a5e54982b8d02d6bdc8dee27dd0d5efea0f6d28590ed +AUX gdal-2.4.1-poppler-0.76.patch 699 BLAKE2B 132ff0a3046734e851d12379d049b2e4fdbefcd4bb6949ddf9fa18b856b1ae20d2a2ec9dbcc0d973097cd2ba5f6e72e852b26a93997ffe4b428fe79d44b5c1cf SHA512 09cdd963dbc5e09d211663f54b1cef72eeeda7484ad10b08862907df60aefc068d840e80d4fd0aa0776a03edca89e8affb8b614c4db02085e854bb4a14342d4f DIST gdal-2.3.1.tar.gz 14450452 BLAKE2B 226ddf80ff8b9e3d420ac717b245a09fe3daa0331931f4d371b62ab9fa9bb0735ca11e1e045398de92d61b68815aa1dc3e7b6568f4853964cf42d188e46e6eb7 SHA512 0c5bb515dd2a9ad3110421b39bd680ce7e9de68e969cf35a7e63118965dbe193d25a7720a525e53af153de3e78f76ccc6983f4dcdfa6ba429d732a7a47a35d57 DIST gdal-2.4.0.tar.gz 14533664 BLAKE2B ec10a4a9ba438a758131c1b80286b27ee17f1f270e77af61d70ed4149d63b9224c98db9c55156075ebd86b5f0875c626d87df3779f0b981895ff1c00786f908e SHA512 9517b23009621ed2622a460dc813b30de726d293531c6f107fb308a31e45a143e67e71aa3af3d1faed554ad516a35924973d714c63ee41445ac8d3b2da61dd10 DIST gdal-2.4.1.tar.gz 14546610 BLAKE2B 92404336339c6f46877f3e6599af6fc67a53714888ff66fc0142efa8ddf185ad34d9ec337dcbad67f059041da31e70073a9e41872a7332fd9977552d79fcbc61 SHA512 b25e49f343986af6f37e0bec6dc3084cbcf1a0080da5cfd91d1a58c1d9ffd2ac355299d66534e63e89358cbb15ecd0f2ae934d91bbd2a3749889dadaf266e483 EBUILD gdal-2.3.1.ebuild 8396 BLAKE2B 9f1237ca5566fcbf9cd96d8625fab6378e177659a5df2016c8b3a6f91ef6294a9ae1fcf1e9daa37f464ba77376a183a1be551831b1e3b07f4462a582999d381b SHA512 5c90139465932d1b503e26a401afaecd4388e3e34b8db86505931cd4aac1702457a91fedc5557ab5bc5d31c46a86d03a9cf8046d315800dc4529e1fbd7ec4bf6 -EBUILD gdal-2.4.0.ebuild 8302 BLAKE2B 31e64b20c812786e4cc27a103e85838a38d6082bdf517f16cf8363b35cf18eb40a19853efcb2d37e739d137daa3d01bcb5c9769b314f26a0e9ed75250358692c SHA512 fcca09c9aee575decbf9a59695a4865f0c488242415812554868a85bbfa5aea7306306f756154ddd32daeb8e95c16e086d11b4b23cc54f9341c9a1c9df95d2c5 -EBUILD gdal-2.4.1.ebuild 8055 BLAKE2B b2bb41dfd1a38c6465c2b917dea123bfbca350edf7f6dbf0a3f47db4f202f04f30135228593f6ccec1c2c4296084de3876fca21170e9dde90e9171b5f8222fe1 SHA512 3dbb42c30039f5466472fac3e8b994ee0df823ba8cc74fa2318b3f4a71f0f343107201f7ce9b3cf77f3afae05480f571a032168b86ffd89b9d31ef26a47c418c +EBUILD gdal-2.4.0.ebuild 8297 BLAKE2B b04defd05cdadb3d7ebc78b5b5389e8cdbbd66287d6e0388476b87d749920152862b65d4ce6cc8f4af2c2711a4e35c68e9a52e3e8791ec081600e540788ea3a3 SHA512 e1832e54c9582bcba56db4f5a95dd400787b9cb7ccb0e607662fda1a3ee73cb9d0d99e6a42e9406f6b52a27d6ba8a472b0a602fbe87009ec85ee250a170a9f56 +EBUILD gdal-2.4.1.ebuild 8117 BLAKE2B 2d056d0c11b0c3ccf54800dbd2764641bb80c910679357e36eff8e9d7a0da527ea839f37df0ea01a26d4ec27b84140a69dd2963aed3104853009a9b4b23b8046 SHA512 82eb5e04061c799ae95781d4c9b2515bacc5d09b00e95c9f4038d150fed74df704b2197775051e484a88d6178a6f94b0bfe2c6ad3141b3177744223a7394b657 MISC metadata.xml 1522 BLAKE2B b67678f81739e2fb2866cc6ca49545368fce4a85b145ba3f8228b8a39ecb2d7f75b55500f13768838c9ed11a47f586ab7b05eb31e2dbf6fcd4d29c5d8896107f SHA512 091112e555a5a77c5643cbd4465046bfd9fe287e209b42f5410787a2f1a2e4d7ec640efad93c277f0f6581db2264fa104d5aba2e8cbc4126c2c14fe4d86afcee diff --git a/sci-libs/gdal/files/gdal-2.4.1-poppler-0.75.patch b/sci-libs/gdal/files/gdal-2.4.1-poppler-0.75.patch new file mode 100644 index 000000000000..49824022b3be --- /dev/null +++ b/sci-libs/gdal/files/gdal-2.4.1-poppler-0.75.patch @@ -0,0 +1,148 @@ +From 5c12d11614a325317ceaa7c0567070b3e4188275 Mon Sep 17 00:00:00 2001 +From: Even Rouault <even.rouault@spatialys.com> +Date: Tue, 26 Mar 2019 12:43:59 +0100 +Subject: [PATCH] Add support for Poppler 0.75.0 (fixes #1388) + +--- + gdal/frmts/pdf/pdfio.h | 5 --- + gdal/frmts/pdf/pdfobject.cpp | 59 ++++++++---------------------------- + 2 files changed, 12 insertions(+), 52 deletions(-) + +diff --git a/frmts/pdf/pdfio.h b/frmts/pdf/pdfio.h +index 7ae15c88aa3..ec13b8fe94c 100644 +--- a/frmts/pdf/pdfio.h ++++ b/frmts/pdf/pdfio.h +@@ -93,11 +93,6 @@ class VSIPDFFileStream final: public BaseStream + virtual void close() override; + + private: +- /* getChars/hasGetChars added in poppler 0.15.0 +- * POPPLER_BASE_STREAM_HAS_TWO_ARGS true from poppler 0.16, +- * This test will be wrong for poppler 0.15 or 0.16, +- * but will still compile correctly. +- */ + virtual GBool hasGetChars() override; + virtual int getChars(int nChars, Guchar *buffer) override; + +diff --git a/frmts/pdf/pdfobject.cpp b/frmts/pdf/pdfobject.cpp +--- a/frmts/pdf/pdfobject.cpp ++++ b/frmts/pdf/pdfobject.cpp +@@ -1195,7 +1195,7 @@ GDALPDFObject* GDALPDFDictionaryPoppler::Get(const char* pszKey) + return oIter->second; + + #if POPPLER_MAJOR_VERSION >= 1 || POPPLER_MINOR_VERSION >= 58 +- Object o = m_poDict->lookupNF(((char*)pszKey)); ++ auto&& o(m_poDict->lookupNF(((char*)pszKey))); + if (!o.isNull()) + { + int nRefNum = 0; +@@ -1204,7 +1204,7 @@ GDALPDFObject* GDALPDFDictionaryPoppler::Get(const char* pszKey) + { + nRefNum = o.getRefNum(); + nRefGen = o.getRefGen(); +- Object o2 = m_poDict->lookup((char*)pszKey); ++ Object o2(m_poDict->lookup((char*)pszKey)); + if( !o2.isNull() ) + { + GDALPDFObjectPoppler* poObj = new GDALPDFObjectPoppler(new Object(std::move(o2)), TRUE); +@@ -1215,7 +1215,7 @@ GDALPDFObject* GDALPDFDictionaryPoppler::Get(const char* pszKey) + } + else + { +- GDALPDFObjectPoppler* poObj = new GDALPDFObjectPoppler(new Object(std::move(o)), TRUE); ++ GDALPDFObjectPoppler* poObj = new GDALPDFObjectPoppler(new Object(std::move(o.copy())), TRUE); + poObj->SetRefNumAndGen(nRefNum, nRefGen); + m_map[pszKey] = poObj; + return poObj; +@@ -1329,7 +1329,7 @@ GDALPDFObject* GDALPDFArrayPoppler::Get(int nIndex) + return m_v[nIndex]; + + #if POPPLER_MAJOR_VERSION >= 1 || POPPLER_MINOR_VERSION >= 58 +- Object o = m_poArray->getNF(nIndex); ++ auto&& o(m_poArray->getNF(nIndex)); + if( !o.isNull() ) + { + int nRefNum = 0; +@@ -1338,7 +1338,7 @@ GDALPDFObject* GDALPDFArrayPoppler::Get(int nIndex) + { + nRefNum = o.getRefNum(); + nRefGen = o.getRefGen(); +- Object o2 = m_poArray->get(nIndex); ++ Object o2(m_poArray->get(nIndex)); + if( !o2.isNull() ) + { + GDALPDFObjectPoppler* poObj = new GDALPDFObjectPoppler(new Object(std::move(o2)), TRUE); +@@ -1349,7 +1349,7 @@ GDALPDFObject* GDALPDFArrayPoppler::Get(int nIndex) + } + else + { +- GDALPDFObjectPoppler* poObj = new GDALPDFObjectPoppler(new Object(std::move(o)), TRUE); ++ GDALPDFObjectPoppler* poObj = new GDALPDFObjectPoppler(new Object(std::move(o.copy())), TRUE); + poObj->SetRefNumAndGen(nRefNum, nRefGen); + m_v[nIndex] = poObj; + return poObj; +@@ -1416,8 +1416,6 @@ int GDALPDFStreamPoppler::GetLength() + + char* GDALPDFStreamPoppler::GetBytes() + { +- /* fillGooString() available in poppler >= 0.16.0 */ +-#ifdef POPPLER_BASE_STREAM_HAS_TWO_ARGS + GooString* gstr = new GooString(); + m_poStream->fillGooString(gstr); + +@@ -1427,7 +1425,12 @@ char* GDALPDFStreamPoppler::GetBytes() + char* pszContent = (char*) VSIMalloc(m_nLength + 1); + if (pszContent) + { +- memcpy(pszContent, gstr->getCString(), m_nLength); ++#if (POPPLER_MAJOR_VERSION >= 1 || POPPLER_MINOR_VERSION >= 72) ++ const char* srcStr = gstr->c_str(); ++#else ++ const char* srcStr = gstr->getCString(); ++#endif ++ memcpy(pszContent, srcStr, m_nLength); + pszContent[m_nLength] = '\0'; + } + delete gstr; +@@ -1438,41 +1441,6 @@ char* GDALPDFStreamPoppler::GetBytes() + delete gstr; + return nullptr; + } +-#else +- int i; +- int nLengthAlloc = 0; +- char* pszContent = nullptr; +- if( m_nLength >= 0 ) +- { +- pszContent = (char*) VSIMalloc(m_nLength + 1); +- if (!pszContent) +- return nullptr; +- nLengthAlloc = m_nLength; +- } +- m_poStream->reset(); +- for(i = 0; ; ++i ) +- { +- int nVal = m_poStream->getChar(); +- if (nVal == EOF) +- break; +- if( i >= nLengthAlloc ) +- { +- nLengthAlloc = 32 + nLengthAlloc + nLengthAlloc / 3; +- char* pszContentNew = (char*) VSIRealloc(pszContent, nLengthAlloc + 1); +- if( pszContentNew == nullptr ) +- { +- CPLFree(pszContent); +- m_nLength = 0; +- return nullptr; +- } +- pszContent = pszContentNew; +- } +- pszContent[i] = (GByte)nVal; +- } +- m_nLength = i; +- pszContent[i] = '\0'; +- return pszContent; +-#endif + } + + #endif // HAVE_POPPLER diff --git a/sci-libs/gdal/files/gdal-2.4.1-poppler-0.76.patch b/sci-libs/gdal/files/gdal-2.4.1-poppler-0.76.patch new file mode 100644 index 000000000000..f15e540932d1 --- /dev/null +++ b/sci-libs/gdal/files/gdal-2.4.1-poppler-0.76.patch @@ -0,0 +1,24 @@ +From 8958528f9b5737581afa7249b0e16f2ff89d727e Mon Sep 17 00:00:00 2001 +From: Even Rouault <even.rouault@spatialys.com> +Date: Sun, 21 Apr 2019 12:19:56 +0200 +Subject: [PATCH] PDF: add support for Poppler 0.76.0 + +--- + gdal/frmts/pdf/pdfsdk_headers.h | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/frmts/pdf/pdfsdk_headers.h b/frmts/pdf/pdfsdk_headers.h +index 41e48ae91d6..1f77429bf9b 100644 +--- a/frmts/pdf/pdfsdk_headers.h ++++ b/frmts/pdf/pdfsdk_headers.h +@@ -55,7 +55,10 @@ + #else + typedef unsigned char Guchar; + #endif ++ ++#if !(POPPLER_MAJOR_VERSION >= 1 || POPPLER_MINOR_VERSION >= 76) + #include <goo/GooList.h> ++#endif + + /* begin of poppler xpdf includes */ + #include <poppler/Object.h> diff --git a/sci-libs/gdal/gdal-2.4.0.ebuild b/sci-libs/gdal/gdal-2.4.0.ebuild index 67fd2d0fa327..32a0cbe2453b 100644 --- a/sci-libs/gdal/gdal-2.4.0.ebuild +++ b/sci-libs/gdal/gdal-2.4.0.ebuild @@ -15,7 +15,7 @@ SRC_URI="https://download.osgeo.org/${PN}/${PV}/${P}.tar.gz" SLOT="0/2.3" LICENSE="BSD Info-ZIP MIT" -KEYWORDS="~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos" +KEYWORDS="amd64 ~arm arm64 ~ia64 ppc ppc64 ~sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos" IUSE="armadillo +aux_xml curl debug doc fits geos gif gml hdf5 java jpeg jpeg2k lzma mdb mysql netcdf odbc ogdi opencl oracle pdf perl png postgres python spatialite sqlite threads webp xls zstd" COMMON_DEPEND=" diff --git a/sci-libs/gdal/gdal-2.4.1.ebuild b/sci-libs/gdal/gdal-2.4.1.ebuild index 303bd716b48f..ac9b89603d03 100644 --- a/sci-libs/gdal/gdal-2.4.1.ebuild +++ b/sci-libs/gdal/gdal-2.4.1.ebuild @@ -82,6 +82,8 @@ PATCHES=( "${FILESDIR}/${PN}-2.2.3-soname.patch" "${FILESDIR}/${PN}-2.2.3-bashcomp-path.patch" # bug 641866 "${FILESDIR}/${PN}-2.3.0-curl.patch" # bug 659840 + "${FILESDIR}/${P}-poppler-0.75.patch" + "${FILESDIR}/${P}-poppler-0.76.patch" ) src_prepare() { @@ -174,7 +176,6 @@ src_configure() { --without-rasterlite2 --without-pcraster --without-pdfium - --without-php --without-podofo --without-qhull --without-sde |