On Thu, Nov 01, 2018 at 12:10:19AM +0000, Stuart Henderson wrote: > On 2018/10/31 15:00, George Koehler wrote: > > mupdf's MD5 code is broken on all big-endian machines. > > https://bugs.ghostscript.com/show_bug.cgi?id=699395 > > > > I added a small patch (not the one in the bug report) and mailed it to > > maintainer Stuart Henderson on Monday. I don't know if MD5 works, but > > I can open a few PDF files. > > I am looking into mupdf, I was already partway through updating to the newer > version but ran into lld-related problems that need figuring out (there is > the libssl-related thing you noticed too, actually that code is disabled > completely at the moment as it doesn't pass the pkg-config version check, > but if that's hacked away build fails due to libressl not having > PKCS12_SAFEBAG > accessors yet). > > > A copy of patch-thirdparty_lcms2_src_cmsmd5_c: > > =begin > > $OpenBSD$ > > > > Fix "error: 'ContextID' undeclared" on big-endian machines. > > The argument will get ignored, so it can be NULL. > > > > Index: thirdparty/lcms2/src/cmsmd5.c > > --- thirdparty/lcms2/src/cmsmd5.c.orig > > +++ thirdparty/lcms2/src/cmsmd5.c > > @@ -33,7 +33,7 @@ void byteReverse(cmsUInt8Number * buf, cmsUInt32Number > > { > > do { > > > > - cmsUInt32Number t = _cmsAdjustEndianess32(ContextID, > > *(cmsUInt32Number *) buf); > > + cmsUInt32Number t = _cmsAdjustEndianess32(NULL, *(cmsUInt32Number > > *) buf); > > *(cmsUInt32Number *) buf = t; > > buf += sizeof(cmsUInt32Number); > > > > =end
Fwid mupdf packaged fine in the current powerpc bulk with this diff. Landry