Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 818457 - app-text/qpdfview-0.4.18_p1 - /.../ld: cannot find -lmupdf-third
Summary: app-text/qpdfview-0.4.18_p1 - /.../ld: cannot find -lmupdf-third
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Qt Bug Alias
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-10-16 10:52 UTC by Toralf Förster
Modified: 2024-02-15 15:06 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge-info.txt (emerge-info.txt,17.79 KB, text/plain)
2021-10-16 10:52 UTC, Toralf Förster
Details
app-text:qpdfview-0.4.18_p1:20211016-094938.log (app-text:qpdfview-0.4.18_p1:20211016-094938.log,13.93 KB, text/plain)
2021-10-16 10:52 UTC, Toralf Förster
Details
emerge-history.txt (emerge-history.txt,468.97 KB, text/plain)
2021-10-16 10:52 UTC, Toralf Förster
Details
environment (environment,63.64 KB, text/plain)
2021-10-16 10:52 UTC, Toralf Förster
Details
etc.portage.tar.bz2 (etc.portage.tar.bz2,45.44 KB, application/x-bzip)
2021-10-16 10:52 UTC, Toralf Förster
Details
temp.tar.bz2 (temp.tar.bz2,17.95 KB, application/x-bzip)
2021-10-16 10:53 UTC, Toralf Förster
Details
Patch that (hackily?) removes the dependency on mupdf-third (no-mupdf-third.patch,498 bytes, patch)
2023-08-25 14:03 UTC, Sophie Hamilton
Details | Diff
build.log (ppc64, 0.5) (qpdfview-0.5:20240215-142441.log,6.96 KB, text/plain)
2024-02-15 15:06 UTC, ernsteiswuerfel
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Toralf Förster gentoo-dev 2021-10-16 10:52:53 UTC
rm -f libqpdfview_fitz.so
x86_64-pc-linux-gnu-g++ -Wl,-O1 -Wl,--as-needed -Wl,--defsym=__gentoo_check_ldflags__=0 -shared -o libqpdfview_fitz.so objects-fitz/fitzmodel.o objects-fitz/moc_model.o objects-fitz/moc_fitzmodel.o  -lmupdf -lmupdf-third -ljpeg /usr/lib64/libQt5Widgets.so /usr/lib64/libQt5Gui.so /usr/lib64/libQt5Core.so -lGL -lpthread    
/usr/lib/gcc/x86_64-pc-linux-gnu/11.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: cannot find -lmupdf-third
collect2: error: ld returned 1 exit status
make[1]: *** [Makefile.fitz-plugin:293: libqpdfview_fitz.so] Error 1
make[1]: Leaving directory '/var/tmp/portage/app-text/qpdfview-0.4.18_p1/work/qpdfview-0.4.18_p1'
make: *** [Makefile:46: sub-fitz-plugin-pro-make_first-ordered] Error 2

  -------------------------------------------------------------------

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 17.1_desktop_plasma_systemd-j4-20211008-163310

  -------------------------------------------------------------------

gcc-config -l:
 [1] x86_64-pc-linux-gnu-11.2.0 *
/usr/lib/llvm/13
13.0.0
Python 3.9.7
Available Ruby profiles:
  [1]   ruby26 (with Rubygems)
  [2]   ruby27 (with Rubygems)
  [3]   ruby30 (with Rubygems) *
Available Rust versions:
  [1]   rust-1.55.0 *
The Glorious Glasgow Haskell Compilation System, version 8.10.4
php cli:
  [1]   php7.3 *
  [2]   php7.4
  [3]   php8.0

  HEAD of ::gentoo
commit 48bb438fe3a3fe47a12acef30c0fcf66a68f02e6
Author: Repository mirror & CI <repomirrorci@gentoo.org>
Date:   Sat Oct 16 09:36:35 2021 +0000

    2021-10-16 09:36:34 UTC

emerge -qpvO app-text/qpdfview
[ebuild  N    ] app-text/qpdfview-0.4.18_p1  USE="cups dbus fitz sqlite svg -djvu -pdf -postscript -synctex"
Comment 1 Toralf Förster gentoo-dev 2021-10-16 10:52:54 UTC
Created attachment 745152 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2021-10-16 10:52:55 UTC
Created attachment 745155 [details]
app-text:qpdfview-0.4.18_p1:20211016-094938.log
Comment 3 Toralf Förster gentoo-dev 2021-10-16 10:52:56 UTC
Created attachment 745158 [details]
emerge-history.txt
Comment 4 Toralf Förster gentoo-dev 2021-10-16 10:52:58 UTC
Created attachment 745161 [details]
environment
Comment 5 Toralf Förster gentoo-dev 2021-10-16 10:52:59 UTC
Created attachment 745164 [details]
etc.portage.tar.bz2
Comment 6 Toralf Förster gentoo-dev 2021-10-16 10:53:00 UTC
Created attachment 745167 [details]
temp.tar.bz2
Comment 7 Sophie Hamilton 2023-08-25 14:00:11 UTC
This appears to be an issue for me on my system as well.

USE="fitz" is masked in base/package.use.stable.mask with the reason:

> # Mask experimental feature on stable. This also needs not yet stable mupdf.

The mask was applied more than 8 years ago on 2015-02-20 (which was before the git transition, but can be seen in the conversion of the CVS repo here: https://gitweb.gentoo.org/archive/repo/gentoo-2.git/commit/?id=3f782dd503257d98adf0b5c5146892c96a97f023 , though it was moved a few minutes later to package.use.stable.mask), and needless to say, we are long past the necessary version of mupdf not being stable.

Looking a little more deeply, it appears that mupdf-third.a is a statically-built library and is only built if not building shared, as far as I can tell from looking at mupdf's Makefile. However, I was able to successfully build qpdfview with fitz support by just removing the link dependency to mupdf-third using the patch I'll include in my next post.

I do not know if this is a stable solution or not - I would imagine not - but so far I haven't had any issues, and building with fitz support has improved the quality of qpdfview's PDF rendering for me.
Comment 8 Sophie Hamilton 2023-08-25 14:03:31 UTC
Created attachment 868679 [details, diff]
Patch that (hackily?) removes the dependency on mupdf-third

Using this patch I'm able to build qpdfview with USE="-pdf fitz" and it seems to work fine, but I'm pretty sure this is not how it's meant to be done. Still, it might help?
Comment 9 Sophie Hamilton 2023-08-27 23:31:34 UTC
Quick update: Using the above patch renders the "Rotate Left"/"Rotate Right" functions unusable; attempting to display the PDF at any rotation other than the default will result in pages showing up as completely blank.
Comment 10 ernsteiswuerfel archtester 2024-02-15 15:06:03 UTC
Created attachment 885049 [details]
build.log (ppc64, 0.5)

Still an issue in 0.5.

I can confirm that Sophies' patch works, but with its' side effects. ;)