Not sure the "used by ocrmypdf" in DESCR really makes sense - might be
worth mentioning in ocrmypdf DESCR though tbh I'd probably just add as RDEP
"base-clang ports-gcc ports-clang" is simpler written as "base-clang
ports-gcc" because there's not going to be any arch with ports-clang but
without ports-gcc
--
Sent from a phone, apologies for poor formatting.
On 28 November 2026 11:50:11 Marc Espie <[email protected]> wrote:
On Sat, Nov 28, 2026 at 11:22:56AM +0000, [email protected] wrote:
På lørdag 28. november 2026 kl. 11:58, skrev Marc Espie:
> Noticed a warning while using ocrmypdf, and investigated.
>
> Turns out ocrmypdf can work in tandem with jbig2enc to compress
> parts of the scanned pdf using the text info it gathered.
>
> The results are fairly pleasant:I passed a full scanned book thru
> orcmypdf.
>
> Results:
> 12082012 bytes without jbig2enc
> 10059811 bytes with jbig2enc
>
> with no visible degradation, as far as I can see.
>
> Port is decently trivial, there's just a small patch, because
> meson might try to build giflib is not already there, and it
> auto-detects using a pkgconfig file we don't have, but I've
> checked: giflib is only brought in thru leptonica and there's
> zero mention of giflib artifacts anywhere in the code.
>
> Requires C++17, hence the COMPILER line, but I doubt it will
> be of much use on older architectures anyway.
>
> ocrmypdf picks it up automatically if it's installed, with no
> need to do anything.
>
> The PATENTS file is there just as a safeguard. Reading the Annex I
> of fcd14492.pdf, the most recent patent referenced was filed in 1997.
> So it expired a few years ago.
>
> Port is attached
>
Current/amd64. No nits I could find. Regression test passed. Checks:
jbig2enc-0.32(graphics/jbig2enc):
Extra: pthread.28
--
That one can't be avoided, it's an artifact of the COMPILER framework and
innocuous.