xpdfwrapper/pdfioutdev_gpl.hxx:227:22: error: ‘virtual void pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ marked ‘override’, but does not override

classic Classic list List threaded Threaded
5 messages Options
Дилян Палаузов Дилян Палаузов
Reply | Threaded
Open this post in threaded view
|

xpdfwrapper/pdfioutdev_gpl.hxx:227:22: error: ‘virtual void pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ marked ‘override’, but does not override

Hello,

LO 6.0.7.3 fails compiling with gcc 8.2.1 20190101 I emitting:

[build SPP] scp2/source/ooo/ure
[build SCP] scp2/source/writer/file_writer
[build SPP] scp2/source/xsltfilter/file_xsltfilter
[build SPP] scp2/source/xsltfilter/module_xsltfilter
[build SPP] scp2/source/gnome/file_gnome
[build SPP] scp2/source/gnome/module_gnome
[build SPP] scp2/source/sdkoo/sdkoo
[build SCP] scp2/source/writer/module_writer
[build CXX] sdext/source/pdfimport/xpdfwrapper/pnghelper.cxx
In file included from /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pnghelper.hxx:24,
                 from /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pnghelper.cxx:20:
/src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx:227:22: error: ‘virtual void
pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ marked ‘override’, but does not override
         virtual void drawString(GfxState *state, const GooString *s) override;
                      ^~~~~~~~~~
/src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx:227:22: warning:   by ‘virtual void
pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ [-Woverloaded-virtual]
make[1]: *** [/src/libreoffice-6.0.7.3/solenv/gbuild/LinkTarget.mk:293: /src/libreoffice-
6.0.7.3/workdir/CxxObject/sdext/source/pdfimport/xpdfwrapper/pnghelper.o] Error 1
make[1]: *** Waiting for unfinished jobs....
[build CXX] sdext/source/pdfimport/xpdfwrapper/wrapper_gpl.cxx
In file included from /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/wrapper_gpl.cxx:20:
/src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx:227:22: error: ‘virtual void
pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ marked ‘override’, but does not override
         virtual void drawString(GfxState *state, const GooString *s) override;
                      ^~~~~~~~~~
/src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx:227:22: warning:   by ‘virtual void
pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ [-Woverloaded-virtual]
make[1]: *** [/src/libreoffice-6.0.7.3/solenv/gbuild/LinkTarget.mk:293: /src/libreoffice-
6.0.7.3/workdir/CxxObject/sdext/source/pdfimport/xpdfwrapper/wrapper_gpl.o] Error 1
[build CXX] sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx
In file included from /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx:20:
/src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx:227:22: error: ‘virtual void
pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ marked ‘override’, but does not override
         virtual void drawString(GfxState *state, const GooString *s) override;
                      ^~~~~~~~~~
/src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx:227:22: warning:   by ‘virtual void
pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ [-Woverloaded-virtual]
make[1]: *** [/src/libreoffice-6.0.7.3/solenv/gbuild/LinkTarget.mk:293: /src/libreoffice-
6.0.7.3/workdir/CxxObject/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.o] Error 1

[ https://bugs.documentfoundation.org/show_bug.cgi?id=122690 ]

Regards
 Дилян

_______________________________________________
LibreOffice mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/libreoffice
sberg sberg
Reply | Threaded
Open this post in threaded view
|

Re: xpdfwrapper/pdfioutdev_gpl.hxx:227:22: error: ‘virtual void pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ marked ‘override’, but does not override

On 13/01/2019 23:57, Дилян Палаузов wrote:

> LO 6.0.7.3 fails compiling with gcc 8.2.1 20190101 I emitting:
>
> [build SPP] scp2/source/ooo/ure
> [build SCP] scp2/source/writer/file_writer
> [build SPP] scp2/source/xsltfilter/file_xsltfilter
> [build SPP] scp2/source/xsltfilter/module_xsltfilter
> [build SPP] scp2/source/gnome/file_gnome
> [build SPP] scp2/source/gnome/module_gnome
> [build SPP] scp2/source/sdkoo/sdkoo
> [build SCP] scp2/source/writer/module_writer
> [build CXX] sdext/source/pdfimport/xpdfwrapper/pnghelper.cxx
> In file included from /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pnghelper.hxx:24,
>                   from /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pnghelper.cxx:20:
> /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx:227:22: error: ‘virtual void
> pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ marked ‘override’, but does not override
>           virtual void drawString(GfxState *state, const GooString *s) override;
>                        ^~~~~~~~~~
> /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx:227:22: warning:   by ‘virtual void
> pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ [-Woverloaded-virtual]
> make[1]: *** [/src/libreoffice-6.0.7.3/solenv/gbuild/LinkTarget.mk:293: /src/libreoffice-

You likely need a backport of
<https://gerrit.libreoffice.org/plugins/gitiles/core/+/42cebff14f7d486c20f04863681cc5ef4602f4eb%5E!/>
"fix build with poppler 0.64" (and maybe also backports of further
poppler-adaption fixes in that area), or configure --without-system-poppler.

There is obviously always a chance that building old versions of LO
against current system components does not work.  Often enough, you will
find fixes for those issues in later versions of LO, and which are often
even easy to backport to the version where you need them.
_______________________________________________
LibreOffice mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/libreoffice
Kaganski Mike Kaganski Mike
Reply | Threaded
Open this post in threaded view
|

Re: xpdfwrapper/pdfioutdev_gpl.hxx:227:22: error: ‘virtual void pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ marked ‘override’, but does not override

On 14.01.2019 11:46, Stephan Bergmann wrote:

> On 13/01/2019 23:57, Дилян Палаузов wrote:
>> LO 6.0.7.3 fails compiling with gcc 8.2.1 20190101 I emitting:
>>
>> [build SPP] scp2/source/ooo/ure
>> [build SCP] scp2/source/writer/file_writer
>> [build SPP] scp2/source/xsltfilter/file_xsltfilter
>> [build SPP] scp2/source/xsltfilter/module_xsltfilter
>> [build SPP] scp2/source/gnome/file_gnome
>> [build SPP] scp2/source/gnome/module_gnome
>> [build SPP] scp2/source/sdkoo/sdkoo
>> [build SCP] scp2/source/writer/module_writer
>> [build CXX] sdext/source/pdfimport/xpdfwrapper/pnghelper.cxx
>> In file included from
>> /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pnghelper.hxx:24,
>>
>>                   from
>> /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pnghelper.cxx:20:
>>
>> /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx:227:22:
>> error: ‘virtual void
>> pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ marked
>> ‘override’, but does not override
>>           virtual void drawString(GfxState *state, const GooString *s)
>> override;
>>                        ^~~~~~~~~~
>> /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx:227:22:
>> warning:   by ‘virtual void
>> pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’
>> [-Woverloaded-virtual]
>> make[1]: ***
>> [/src/libreoffice-6.0.7.3/solenv/gbuild/LinkTarget.mk:293:
>> /src/libreoffice-
>
> You likely need a backport of
> <https://gerrit.libreoffice.org/plugins/gitiles/core/+/42cebff14f7d486c20f04863681cc5ef4602f4eb%5E!/>
> "fix build with poppler 0.64" (and maybe also backports of further
> poppler-adaption fixes in that area), or configure
> --without-system-poppler.
>
> There is obviously always a chance that building old versions of LO
> against current system components does not work.  Often enough, you will
> find fixes for those issues in later versions of LO, and which are often
> even easy to backport to the version where you need them.

I'm afraid that the message implies that the fix from spring 2018 is
already there - the constness of the GooString parameter is there in the
message. So possibly there's some problem detecting the poppler library
version?

--
Best regards,
Mike Kaganski
_______________________________________________
LibreOffice mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/libreoffice
Дилян Палаузов-2 Дилян Палаузов-2
Reply | Threaded
Open this post in threaded view
|

Re: xpdfwrapper/pdfioutdev_gpl.hxx:227:22: error: ‘virtual void pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ marked ‘override’, but does not override

Hello,

the LO source code requires const GooString*, but the /usr/local/include/poppler/OutputDev.h file had no const in the
declaration of drawString.  The installed poppler was newer than 0.64.0.

The hack is, that in the past I installed poppler and it installed OutputDev.h .  When I later compiled newer version of
poppler I have not passed ENABLE_XPDF_HEADERS / ENABLE_UNSTABLE_API_ABI_HEADERS to cmake and in turn “make install” has
not overwritten /usr/local/include/poppler/OutputDev.h.  This led to a situation with new libpoppler and old OutputDev.h
without const.  Indeed override triggered correctly.

--without-system-poppler mitigates.

Regards
  Дилян

On Mon, 2019-01-14 at 08:48 +0000, Kaganski Mike wrote:

> On 14.01.2019 11:46, Stephan Bergmann wrote:
> > On 13/01/2019 23:57, Дилян Палаузов wrote:
> > > LO 6.0.7.3 fails compiling with gcc 8.2.1 20190101 I emitting:
> > >
> > > [build SPP] scp2/source/ooo/ure
> > > [build SCP] scp2/source/writer/file_writer
> > > [build SPP] scp2/source/xsltfilter/file_xsltfilter
> > > [build SPP] scp2/source/xsltfilter/module_xsltfilter
> > > [build SPP] scp2/source/gnome/file_gnome
> > > [build SPP] scp2/source/gnome/module_gnome
> > > [build SPP] scp2/source/sdkoo/sdkoo
> > > [build SCP] scp2/source/writer/module_writer
> > > [build CXX] sdext/source/pdfimport/xpdfwrapper/pnghelper.cxx
> > > In file included from
> > > /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pnghelper.hxx:24,
> > >
> > >                   from
> > > /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pnghelper.cxx:20:
> > >
> > > /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx:227:22:
> > > error: ‘virtual void
> > > pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ marked
> > > ‘override’, but does not override
> > >           virtual void drawString(GfxState *state, const GooString *s)
> > > override;
> > >                        ^~~~~~~~~~
> > > /src/libreoffice-6.0.7.3/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx:227:22:
> > > warning:   by ‘virtual void
> > > pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’
> > > [-Woverloaded-virtual]
> > > make[1]: ***
> > > [/src/libreoffice-6.0.7.3/solenv/gbuild/LinkTarget.mk:293:
> > > /src/libreoffice-
> >
> > You likely need a backport of
> > <https://gerrit.libreoffice.org/plugins/gitiles/core/+/42cebff14f7d486c20f04863681cc5ef4602f4eb%5E!/>
> > "fix build with poppler 0.64" (and maybe also backports of further
> > poppler-adaption fixes in that area), or configure
> > --without-system-poppler.
> >
> > There is obviously always a chance that building old versions of LO
> > against current system components does not work.  Often enough, you will
> > find fixes for those issues in later versions of LO, and which are often
> > even easy to backport to the version where you need them.
>
> I'm afraid that the message implies that the fix from spring 2018 is
> already there - the constness of the GooString parameter is there in the
> message. So possibly there's some problem detecting the poppler library
> version?
>
> --
> Best regards,
> Mike Kaganski
> _______________________________________________
> LibreOffice mailing list
> [hidden email]
> https://lists.freedesktop.org/mailman/listinfo/libreoffice

_______________________________________________
LibreOffice mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/libreoffice
Kaganski Mike Kaganski Mike
Reply | Threaded
Open this post in threaded view
|

Re: xpdfwrapper/pdfioutdev_gpl.hxx:227:22: error: ‘virtual void pdfi::PDFOutDev::drawString(GfxState*, const GooString*)’ marked ‘override’, but does not override

Hi!

On 15.01.2019 1:40, Дилян Палаузов wrote:

> Hello,
>
> the LO source code requires const GooString*, but the /usr/local/include/poppler/OutputDev.h file had no const in the
> declaration of drawString.  The installed poppler was newer than 0.64.0.
>
> The hack is, that in the past I installed poppler and it installed OutputDev.h .  When I later compiled newer version of
> poppler I have not passed ENABLE_XPDF_HEADERS / ENABLE_UNSTABLE_API_ABI_HEADERS to cmake and in turn “make install” has
> not overwritten /usr/local/include/poppler/OutputDev.h.  This led to a situation with new libpoppler and old OutputDev.h
> without const.  Indeed override triggered correctly.
>
> --without-system-poppler mitigates.

All current LibreOffice branches, including 6-0-7, have the patch
mentioned by Stephan previously. You may see the source here:

https://cgit.freedesktop.org/libreoffice/core/tree/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx?h=libreoffice-6-0-7

and the commit to 6-1 here:

https://cgit.freedesktop.org/libreoffice/core/commit?id=106b2c96e9807af14d6eb6e8f83dcf25095a093e

The commit conditionally makes the parameter const when reported poppler
is 0.64 or newer, following the poppler change "Add const to several
classes and members" (see
https://poppler.freedesktop.org/releases.html). Poppler 0.64 and newer
does have the const in the declaration of drawString - you may check its
source code at
https://cgit.freedesktop.org/poppler/poppler/tree/poppler/OutputDev.h?h=poppler-0.64.0,
and the commit is
https://cgit.freedesktop.org/poppler/poppler/commit/poppler/OutputDev.h?h=poppler-0.64.0&id=c4af5981ab2a5f42a9a1194bb5929c2151fc2674.

So the problem in your situation is most likely that you have messed up
with the mix of new and old headers and library.

--
Best regards,
Mike Kaganski
_______________________________________________
LibreOffice mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/libreoffice