--- /dev/null +++ b/converters/pdf2djvu/files/patch-gentoo_pdf2djvu-0.9.12-poppler-0.82-4.patch @@ -0,0 +1,26 @@ +This patch doesn't come from Gentoo, but because there are already +three unrelated patches that touch the same file, I'm following the +naming convention so that it gets applied in the right order. + +Chase constness changes in the poppler API. + +--- pdf2djvu.cc.orig 2019-10-27 19:16:30.654895000 +0000 ++++ pdf2djvu.cc 2019-10-27 19:16:47.450786000 +0000 +@@ -333,7 +333,7 @@ + } + + void drawImage(pdf::gfx::State *state, pdf::Object *object, pdf::Stream *stream, int width, int height, +- pdf::gfx::ImageColorMap *color_map, bool interpolate, int *mask_colors, bool inline_image) ++ pdf::gfx::ImageColorMap *color_map, bool interpolate, const int *mask_colors, bool inline_image) + { + if (is_foreground_color_map(color_map) || config.no_render) + { +@@ -376,7 +376,7 @@ + bool interpretType3Chars() { return false; } + + void drawChar(pdf::gfx::State *state, double x, double y, double dx, double dy, double origin_x, double origin_y, +- CharCode code, int n_bytes, Unicode *unistr, int length) ++ CharCode code, int n_bytes, const Unicode *unistr, int length) + { + double pox, poy, pdx, pdy, px, py, pw, ph; + x -= origin_x; y -= origin_y; --- /dev/null +++ b/converters/pdf2djvu/files/patch-pdf-dpi.cc @@ -0,0 +1,11 @@ +--- pdf-dpi.cc.orig 2019-10-27 19:10:07 UTC ++++ pdf-dpi.cc +@@ -34,7 +34,7 @@ class DpiGuessDevice : public pdf::OutputDevice (prote + } + + virtual void drawImage(pdf::gfx::State *state, pdf::Object *object, pdf::Stream *stream, int width, int height, +- pdf::gfx::ImageColorMap *color_map, bool interpolate, int *mask_colors, bool inline_image) ++ pdf::gfx::ImageColorMap *color_map, bool interpolate, const int *mask_colors, bool inline_image) + { + this->process_image(state, width, height); + } --- /dev/null +++ b/converters/pdf2djvu/files/patch-pdf-unicode.cc @@ -0,0 +1,25 @@ +--- pdf-unicode.cc.orig 2019-10-27 19:19:18.837645000 +0000 ++++ pdf-unicode.cc 2019-10-27 19:20:31.405700000 +0000 +@@ -125,11 +125,11 @@ + * =================== + */ + +-pdf::FullNFKC::FullNFKC(Unicode *unistr, int length) ++pdf::FullNFKC::FullNFKC(const Unicode *unistr, int length) + : data(nullptr), length_(0) + { + assert(length >= 0); +- this->data = unicodeNormalizeNFKC(unistr, length, &this->length_, nullptr); ++ this->data = unicodeNormalizeNFKC(const_cast(unistr), length, &this->length_, nullptr); + } + + pdf::FullNFKC::~FullNFKC() +@@ -141,7 +141,7 @@ + * ====================== + */ + +-pdf::MinimalNFKC::MinimalNFKC(Unicode *unistr, int length) ++pdf::MinimalNFKC::MinimalNFKC(const Unicode *unistr, int length) + { + this->string.append(unistr, length); + } --- /dev/null +++ b/converters/pdf2djvu/files/patch-pdf-unicode.hh @@ -0,0 +1,20 @@ +--- pdf-unicode.hh.orig 2019-10-27 19:18:36.768779000 +0000 ++++ pdf-unicode.hh 2019-10-27 19:19:00.052652000 +0000 +@@ -58,7 +58,7 @@ + Unicode* data; + int length_; + public: +- explicit FullNFKC(Unicode *, int length); ++ explicit FullNFKC(const Unicode *, int length); + ~FullNFKC(); + int length() const + { +@@ -79,7 +79,7 @@ + protected: + std::basic_string string; + public: +- explicit MinimalNFKC(Unicode *, int length); ++ explicit MinimalNFKC(const Unicode *, int length); + int length() const; + operator const Unicode*() const; + }; --- b/editors/calligra/Makefile +++ b/editors/calligra/Makefile @@ -1,8 +1,8 @@ -# $FreeBSD$ +# $FreeBSD: head/editors/calligra/Makefile 515671 2019-10-25 23:41:34Z tcberner $ PORTNAME= calligra DISTVERSION= 3.1.0 -PORTREVISION= 26 +PORTREVISION= 27 CATEGORIES= editors kde MASTER_SITES= KDE/stable/${PORTNAME}/${PORTVERSION} DIST_SUBDIR= KDE/${PORTNAME} @@ -69,8 +69,4 @@ CMAKE_ARGS+= -DCMAKE_CXX_FLAGS="-DKDE_NO_DEBUG_OUTPUT" PLIST_SUB+= SHLIB_VER=16.0.0 -post-patch: - # Fix with poppler 0.73 - ${REINPLACE_CMD} -e 's|Guchar|unsigned char|g' \ - ${WRKSRC}/filters/karbon/pdf/SvgOutputDev.cpp .include --- b/editors/calligra/files/patch-filters_karbon_pdf_SvgOutputDev.cpp +++ b/editors/calligra/files/patch-filters_karbon_pdf_SvgOutputDev.cpp @@ -101,7 +101,7 @@ { int render = state->getRender(); // check for invisible text -- this is used by Acrobat Capture -@@ -402,7 +408,7 @@ void SvgOutputDev::drawString(GfxState * state, GooStr +@@ -402,10 +408,10 @@ void SvgOutputDev::drawString(GfxState * state, GooStr QString str; @@ -109,7 +109,11 @@ + const char * p = s->c_str(); int len = s->getLength(); CharCode code; - Unicode *u = nullptr; +- Unicode *u = nullptr; ++ const Unicode *u = nullptr; + int uLen; + double dx, dy, originX, originY; + while (len > 0) { @@ -429,7 +435,7 @@ void SvgOutputDev::drawString(GfxState * state, GooStr double x = state->getCurX(); double y = state->getCurY(); @@ -144,6 +148,24 @@ { ImageStream * imgStr = new ImageStream(str, width, colorMap->getNumPixelComps(), colorMap->getBits()); imgStr->reset(); +@@ -488,7 +494,7 @@ void SvgOutputDev::drawImage(GfxState *state, Object * + if (maskColors) { + for (int y = 0; y < height; y++) { + dest = (unsigned int *)(buffer + y * 4 * width); +- Guchar * pix = imgStr->getLine(); ++ unsigned char * pix = imgStr->getLine(); + colorMap->getRGBLine(pix, dest, width); + + for (int x = 0; x < width; x++) { +@@ -507,7 +513,7 @@ void SvgOutputDev::drawImage(GfxState *state, Object * + } else { + for (int y = 0; y < height; y++) { + dest = (unsigned int *)(buffer + y * 4 * width); +- Guchar * pix = imgStr->getLine(); ++ unsigned char * pix = imgStr->getLine(); + colorMap->getRGBLine(pix, dest, width); + } + @@ -522,7 +528,7 @@ void SvgOutputDev::drawImage(GfxState *state, Object * return; } --- b/editors/calligra/files/patch-sheets_plugins_calendar_CalendarToolWidget.cpp +++ b/editors/calligra/files/patch-sheets_plugins_calendar_CalendarToolWidget.cpp @@ -3,13 +3,7 @@ From: David Faure Date: Tue, 23 Jul 2019 13:02:34 +0200 Subject: Fix compilation with Qt 5.13 (missing include) ---- - sheets/plugins/calendar/CalendarToolWidget.cpp | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/sheets/plugins/calendar/CalendarToolWidget.cpp b/sheets/plugins/calendar/CalendarToolWidget.cpp -index b10b230..0c5eeb6 100644 ---- sheets/plugins/calendar/CalendarToolWidget.cpp +--- sheets/plugins/calendar/CalendarToolWidget.cpp.orig 2018-01-26 09:24:44 UTC +++ sheets/plugins/calendar/CalendarToolWidget.cpp @@ -30,6 +30,7 @@ #include @@ -19,5 +13,3 @@ index b10b230..0c5eeb6 100644 namespace Calligra { --- -cgit v1.1 --- /dev/null +++ b/editors/libreoffice/files/patch-sdext_source_pdfimport_xpdfwrapper_pdfioutdev__gpl.cxx @@ -0,0 +1,35 @@ +--- sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx.orig 2019-10-27 14:16:14 UTC ++++ sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx +@@ -866,7 +866,7 @@ void PDFOutDev::eoClip(GfxState *state) + void PDFOutDev::drawChar(GfxState *state, double x, double y, + double dx, double dy, + double originX, double originY, +- CharCode, int /*nBytes*/, Unicode *u, int uLen) ++ CharCode, int /*nBytes*/, const Unicode *u, int uLen) + { + assert(state); + +@@ -982,7 +982,7 @@ void PDFOutDev::drawImageMask(GfxState* pState, Object + void PDFOutDev::drawImage(GfxState*, Object*, Stream* str, + int width, int height, GfxImageColorMap* colorMap, + poppler_bool /*interpolate*/, +- int* maskColors, poppler_bool /*inlineImg*/ ) ++ const int* maskColors, poppler_bool /*inlineImg*/ ) + { + if (m_bSkipImages) + return; +@@ -1004,12 +1004,12 @@ void PDFOutDev::drawImage(GfxState*, Object*, Stream* + { + GfxRGB aMinRGB; + colorMap->getColorSpace()->getRGB( +- reinterpret_cast(maskColors), ++ reinterpret_cast(maskColors), + &aMinRGB ); + + GfxRGB aMaxRGB; + colorMap->getColorSpace()->getRGB( +- reinterpret_cast(maskColors)+gfxColorMaxComps, ++ reinterpret_cast(maskColors)+gfxColorMaxComps, + &aMaxRGB ); + + aMaskBuf.push_back( colToByte(aMinRGB.r) ); --- /dev/null +++ b/editors/libreoffice/files/patch-sdext_source_pdfimport_xpdfwrapper_pdfioutdev__gpl.hxx @@ -0,0 +1,39 @@ +--- sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx.orig 2019-10-27 14:16:24 UTC ++++ sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx +@@ -232,10 +232,18 @@ namespace pdfi + virtual void eoClip(GfxState *state) override; + + //----- text drawing ++#if POPPLER_CHECK_VERSION(0, 82, 0) + virtual void drawChar(GfxState *state, double x, double y, + double dx, double dy, + double originX, double originY, ++ CharCode code, int nBytes, const Unicode *u, int uLen) override; ++#else ++ virtual void drawChar(GfxState *state, double x, double y, ++ double dx, double dy, ++ double originX, double originY, + CharCode code, int nBytes, Unicode *u, int uLen) override; ++#endif ++ + #if POPPLER_CHECK_VERSION(0, 64, 0) + virtual void drawString(GfxState *state, const GooString *s) override; + #else +@@ -248,10 +256,17 @@ namespace pdfi + int width, int height, poppler_bool invert, + poppler_bool interpolate, + poppler_bool inlineImg) override; ++#if POPPLER_CHECK_VERSION(0, 82, 0) + virtual void drawImage(GfxState *state, Object *ref, Stream *str, + int width, int height, GfxImageColorMap *colorMap, + poppler_bool interpolate, ++ const int* maskColors, poppler_bool inlineImg) override; ++#else ++ virtual void drawImage(GfxState *state, Object *ref, Stream *str, ++ int width, int height, GfxImageColorMap *colorMap, ++ poppler_bool interpolate, + int* maskColors, poppler_bool inlineImg) override; ++#endif + virtual void drawMaskedImage(GfxState *state, Object *ref, Stream *str, + int width, int height, + GfxImageColorMap *colorMap, --- /dev/null +++ b/graphics/inkscape/files/patch-src_extension_internal_pdfinput_pdf-parser.cpp @@ -0,0 +1,20 @@ +--- src/extension/internal/pdfinput/pdf-parser.cpp.orig 2019-10-27 20:00:15.887122000 +0000 ++++ src/extension/internal/pdfinput/pdf-parser.cpp 2019-10-27 20:02:37.972576000 +0000 +@@ -2414,7 +2414,7 @@ + int wMode; + double riseX, riseY; + CharCode code; +- Unicode *u = NULL; ++ const Unicode *u = NULL; + double x, y, dx, dy, tdx, tdy; + double originX, originY, tOriginX, tOriginY; + double oldCTM[6], newCTM[6]; +@@ -2537,7 +2537,7 @@ + originY *= state->getFontSize(); + state->textTransformDelta(originX, originY, &tOriginX, &tOriginY); + builder->addChar(state, state->getCurX() + riseX, state->getCurY() + riseY, +- dx, dy, tOriginX, tOriginY, code, n, u, uLen); ++ dx, dy, tOriginX, tOriginY, code, n, const_cast(u), uLen); + state->shift(tdx, tdy); + p += n; + len -= n; --- b/graphics/poppler-glib/pkg-plist +++ b/graphics/poppler-glib/pkg-plist @@ -16,6 +16,6 @@ include/poppler/glib/poppler.h lib/girepository-1.0/Poppler-0.18.typelib lib/libpoppler-glib.so lib/libpoppler-glib.so.8 -lib/libpoppler-glib.so.8.14.0 +lib/libpoppler-glib.so.8.15.0 libdata/pkgconfig/poppler-glib.pc share/gir-1.0/Poppler-0.18.gir --- b/graphics/poppler/Makefile +++ b/graphics/poppler/Makefile @@ -2,8 +2,8 @@ # $FreeBSD$ PORTNAME= poppler -DISTVERSION= 0.81.0 -PORTREVISION?= 1 +DISTVERSION= 0.82.0 +PORTREVISION?= 0 CATEGORIES= graphics print MASTER_SITES= https://poppler.freedesktop.org/ --- b/graphics/poppler/distinfo +++ b/graphics/poppler/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1569211524 -SHA256 (poppler-0.81.0.tar.xz) = 212d020b035b67b36c9666bd08ac778dff3222d85c01c338787d546f0f9bfe02 -SIZE (poppler-0.81.0.tar.xz) = 1548944 +TIMESTAMP = 1572047126 +SHA256 (poppler-0.82.0.tar.xz) = 234f8e573ea57fb6a008e7c1e56bfae1af5d1adf0e65f47555e1ae103874e4df +SIZE (poppler-0.82.0.tar.xz) = 1553336 --- b/graphics/poppler/pkg-plist +++ b/graphics/poppler/pkg-plist @@ -4,6 +4,9 @@ include/poppler/BuiltinFont.h include/poppler/BuiltinFontTables.h include/poppler/CMap.h include/poppler/CachedFile.h +include/poppler/CairoFontEngine.h +include/poppler/CairoOutputDev.h +include/poppler/CairoRescaleBox.h include/poppler/Catalog.h include/poppler/CertificateInfo.h include/poppler/CharCodeToUnicode.h @@ -132,8 +135,8 @@ lib/libpoppler-cpp.so lib/libpoppler-cpp.so.0 lib/libpoppler-cpp.so.0.7.0 lib/libpoppler.so -lib/libpoppler.so.91 -lib/libpoppler.so.91.0.0 +lib/libpoppler.so.92 +lib/libpoppler.so.92.0.0 libdata/pkgconfig/poppler-cairo.pc libdata/pkgconfig/poppler-cpp.pc libdata/pkgconfig/poppler-splash.pc --- /dev/null +++ b/print/scribus-devel/files/patch-scribus_plugins_import_pdf_slaoutput.cpp @@ -0,0 +1,29 @@ +--- scribus/plugins/import/pdf/slaoutput.cpp.orig 2019-10-27 16:14:24 UTC ++++ scribus/plugins/import/pdf/slaoutput.cpp +@@ -2784,7 +2784,7 @@ void SlaOutputDev::drawMaskedImage(GfxState *state, Ob + delete[] mbuffer; + } + +-void SlaOutputDev::drawImage(GfxState *state, Object *ref, Stream *str, int width, int height, GfxImageColorMap *colorMap, GBool interpolate, int *maskColors, GBool inlineImg) ++void SlaOutputDev::drawImage(GfxState *state, Object *ref, Stream *str, int width, int height, GfxImageColorMap *colorMap, GBool interpolate, const int *maskColors, GBool inlineImg) + { + ImageStream * imgStr = new ImageStream(str, width, colorMap->getNumPixelComps(), colorMap->getBits()); + // qDebug() << "Image Components" << colorMap->getNumPixelComps() << "Mask" << maskColors; +@@ -3365,7 +3365,7 @@ err1: + fontsrc->unref(); + } + +-void SlaOutputDev::drawChar(GfxState *state, double x, double y, double dx, double dy, double originX, double originY, CharCode code, int nBytes, Unicode *u, int uLen) ++void SlaOutputDev::drawChar(GfxState *state, double x, double y, double dx, double dy, double originX, double originY, CharCode code, int nBytes, const Unicode *u, int uLen) + { + double x1, y1, x2, y2; + int render; +@@ -3452,7 +3452,7 @@ void SlaOutputDev::drawChar(GfxState *state, double x, + } + } + +-GBool SlaOutputDev::beginType3Char(GfxState *state, double x, double y, double dx, double dy, CharCode code, Unicode *u, int uLen) ++GBool SlaOutputDev::beginType3Char(GfxState *state, double x, double y, double dx, double dy, CharCode code, const Unicode *u, int uLen) + { + // qDebug() << "beginType3Char"; + GfxFont *gfxFont; --- /dev/null +++ b/print/scribus-devel/files/patch-scribus_plugins_import_pdf_slaoutput.h @@ -0,0 +1,22 @@ +--- scribus/plugins/import/pdf/slaoutput.h.orig 2019-10-27 16:12:47 UTC ++++ scribus/plugins/import/pdf/slaoutput.h +@@ -229,7 +229,7 @@ class SlaOutputDev : public OutputDev (public) + + //----- image drawing + void drawImageMask(GfxState *state, Object *ref, Stream *str, int width, int height, GBool invert, GBool interpolate, GBool inlineImg) override; +- void drawImage(GfxState *state, Object *ref, Stream *str, int width, int height, GfxImageColorMap *colorMap, GBool interpolate, int *maskColors, GBool inlineImg) override; ++ void drawImage(GfxState *state, Object *ref, Stream *str, int width, int height, GfxImageColorMap *colorMap, GBool interpolate, const int *maskColors, GBool inlineImg) override; + void drawSoftMaskedImage(GfxState *state, Object *ref, Stream *str, + int width, int height, + GfxImageColorMap *colorMap, +@@ -261,8 +261,8 @@ class SlaOutputDev : public OutputDev (public) + //----- text drawing + void beginTextObject(GfxState *state) override; + void endTextObject(GfxState *state) override; +- void drawChar(GfxState *state, double /*x*/, double /*y*/, double /*dx*/, double /*dy*/, double /*originX*/, double /*originY*/, CharCode /*code*/, int /*nBytes*/, Unicode * /*u*/, int /*uLen*/) override; +- GBool beginType3Char(GfxState * /*state*/, double /*x*/, double /*y*/, double /*dx*/, double /*dy*/, CharCode /*code*/, Unicode * /*u*/, int /*uLen*/) override; ++ void drawChar(GfxState *state, double /*x*/, double /*y*/, double /*dx*/, double /*dy*/, double /*originX*/, double /*originY*/, CharCode /*code*/, int /*nBytes*/, const Unicode * /*u*/, int /*uLen*/) override; ++ GBool beginType3Char(GfxState * /*state*/, double /*x*/, double /*y*/, double /*dx*/, double /*dy*/, CharCode /*code*/, const Unicode * /*u*/, int /*uLen*/) override; + void endType3Char(GfxState * /*state*/) override; + void type3D0(GfxState * /*state*/, double /*wx*/, double /*wy*/) override; + void type3D1(GfxState * /*state*/, double /*wx*/, double /*wy*/, double /*llx*/, double /*lly*/, double /*urx*/, double /*ury*/) override;