docwire icon indicating copy to clipboard operation
docwire copied to clipboard

Disable podofo

Open pcoramasionwu opened this issue 1 year ago • 4 comments

Is there information on how I may disable podofo in the platform? I don't require it's capability and https://github.com/docwire/docwire/issues/90 is still an issue

pcoramasionwu avatar Mar 22 '24 14:03 pcoramasionwu

Splitting the SDK into a larger number of smaller libraries is planned to be done soon: #103. The final solution will be not to link the docwire_pdf library.

as-ascii avatar Mar 26 '24 22:03 as-ascii

Expected Outcome: Podofo is no longer a dependency to run the SDK without issues

pcoramasionwu avatar Aug 06 '24 13:08 pcoramasionwu

In addition: the documentation should be added what docwire libraries should be explicitly linked to the application for what features and dependencies.

as-ascii avatar Aug 06 '24 14:08 as-ascii

docwire_office_formats library is splitted into smaller libraries:

  • docwire_odf_ooxml
  • docwire_ole_office_formats
  • docwire_xlsb
  • docwire_iwork
  • docwire_rtf
  • docwire_pdf
  • docwire_html
  • docwire_plain_text.

podofo is the dependency of docwire_pdf library only.

docwire_office_formats library can be still used to link easily all of that smaller libraries but there is also a possibility to link smaller libraries directly instead. In this scenario docwire_pdf can be just skipped.

This implementation will be merged to main branch together with other recent changes soon.

as-ascii avatar Aug 13 '24 19:08 as-ascii

In addition "parser_provider" template was added to easily define own parser providers with selected set of parsers. Standard OfficeFormatsParserProvider is now defined as:

using OfficeFormatsParserProvider = parser_provider<
  HTMLParser, DOCParser, PDFParser, XLSParser, XLSBParser, IWorkParser,
  PPTParser, RTFParser, ODFOOXMLParser, ODFXMLParser, TXTParser>;

If docwire_pdf is not linked it is now easy to skip PDFParser defining own set of parsers like this:

using MyOwnOfficeFormatsParserProvider = parser_provider<
  HTMLParser, DOCParser, XLSParser, XLSBParser, IWorkParser, PPTParser,
  RTFParser, ODFOOXMLParser, ODFXMLParser, TXTParser>; // without PDFParser
std::cin | ParseDetectedFormat<MyOwnOfficeFormatsParserProvider, MailParserProvider, OcrParserProvider>{} |
  PlainTextExporter() | std::cout;

as-ascii avatar Aug 14 '24 23:08 as-ascii