Meu ambiente de sistema é Ubuntu 20.04
. Baixei o código-fonte mais recente para qpdfview
(versão 0.5 a partir de agora) em: https://launchpad.net/qpdfview/+download
Instruções de instalação no README
arquivo:
Depende de libQtCore, libQtGui. Também depende de libQtSvg, libQtSql, libQtDBus, libcups, resp. libz se SVG, SQL, D-Bus, CUPS, resp. O suporte SyncTeX está habilitado. Também depende do libmagic se o Qt versão 4 for usado e o suporte ao libmagic estiver habilitado. O plug-in PDF depende de libQtCore, libQtXml, libQtGui e libpoppler-qt4 ou libpoppler-qt5. O plug-in PS depende de libQtCore, libQtGui e libspectre. O plug-in DjVu depende de libQtCore, libQtGui e libdjvulibre. O plug-in Fitz depende de libQtCore, libQtGui e libmupdf.
O plug-in Fitz é atualmente considerado experimental devido à falta de um mantenedor. Também carece de suporte para vários recursos, por exemplo, metadados, criptografia, pesquisa de texto, extração de texto, campos de formulário e anotações.
Ele é construído usando "lrelease qpdfview.pro", "qmake qpdfview.pro" e "make". Ele é instalado usando "make install". Os caminhos de instalação estão definidos em "qpdfview.pri".
Qt5
Ferramentas e dependências instaladas para qpdfview
:
sudo apt install libcups2-dev libmupdf-dev libdjvulibre-dev libspectre-dev libpoppler-qt5-dev qttools5-dev-tools qtbase5-dev qt5-qmake cmake
Compilando pwdfview
com os seguintes comandos:
lrelease qpdfview.pro
qmake qpdfview.pro
make
O último make
comando produz a seguinte saída com erro:
qpdfview-0.5$ make
( test -e Makefile.pdf-plugin || /usr/lib/qt5/bin/qmake -o Makefile.pdf-plugin qpdfview-0.5/pdf-plugin.pro ) && make -f Makefile.pdf-plugin
make[1]: Entering directory 'qpdfview-0.5'
make[1]: Nothing to be done for 'first'.
make[1]: Leaving directory 'qpdfview-0.5'
( test -e Makefile.ps-plugin || /usr/lib/qt5/bin/qmake -o Makefile.ps-plugin qpdfview-0.5/ps-plugin.pro ) && make -f Makefile.ps-plugin
make[1]: Entering directory 'qpdfview-0.5'
make[1]: Nothing to be done for 'first'.
make[1]: Leaving directory 'qpdfview-0.5'
( test -e Makefile.djvu-plugin || /usr/lib/qt5/bin/qmake -o Makefile.djvu-plugin qpdfview-0.5/djvu-plugin.pro ) && make -f Makefile.djvu-plugin
make[1]: Entering directory 'qpdfview-0.5'
make[1]: Nothing to be done for 'first'.
make[1]: Leaving directory 'qpdfview-0.5'
( test -e Makefile.image-plugin || /usr/lib/qt5/bin/qmake -o Makefile.image-plugin qpdfview-0.5/image-plugin.pro ) && make -f Makefile.image-plugin
make[1]: Entering directory 'qpdfview-0.5'
make[1]: Nothing to be done for 'first'.
make[1]: Leaving directory 'qpdfview-0.5'
( test -e Makefile.application || /usr/lib/qt5/bin/qmake -o Makefile.application qpdfview-0.5/application.pro ) && make -f Makefile.application
make[1]: Entering directory 'qpdfview-0.5'
g++ -Wl,-O1 -o qpdfview objects/settings.o objects/pluginhandler.o objects/shortcuthandler.o objects/rendertask.o objects/tileitem.o objects/pageitem.o objects/thumbnailitem.o objects/presentationview.o objects/searchmodel.o objects/searchitemdelegate.o objects/searchtask.o objects/miscellaneous.o objects/documentlayout.o objects/documentview.o objects/printdialog.o objects/settingsdialog.o objects/fontsdialog.o objects/helpdialog.o objects/recentlyusedmenu.o objects/recentlyclosedmenu.o objects/bookmarkmenu.o objects/bookmarkdialog.o objects/bookmarkmodel.o objects/database.o objects/mainwindow.o objects/application.o objects/main.o objects/synctex_parser.o objects/synctex_parser_utils.o objects/signalhandler.o objects/qrc_icons.o objects/moc_settings.o objects/moc_model.o objects/moc_pluginhandler.o objects/moc_shortcuthandler.o objects/moc_rendertask.o objects/moc_pageitem.o objects/moc_thumbnailitem.o objects/moc_presentationview.o objects/moc_searchmodel.o objects/moc_searchitemdelegate.o objects/moc_searchtask.o objects/moc_miscellaneous.o objects/moc_documentview.o objects/moc_printdialog.o objects/moc_settingsdialog.o objects/moc_fontsdialog.o objects/moc_helpdialog.o objects/moc_recentlyusedmenu.o objects/moc_recentlyclosedmenu.o objects/moc_bookmarkmodel.o objects/moc_bookmarkmenu.o objects/moc_bookmarkdialog.o objects/moc_database.o objects/moc_mainwindow.o objects/moc_application.o objects/moc_signalhandler.o -lz /usr/lib/x86_64-linux-gnu/libQt5PrintSupport.so /usr/lib/x86_64-linux-gnu/libQt5Svg.so /usr/lib/x86_64-linux-gnu/libQt5Widgets.so /usr/lib/x86_64-linux-gnu/libQt5Gui.so /usr/lib/x86_64-linux-gnu/libQt5Concurrent.so /usr/lib/x86_64-linux-gnu/libQt5Sql.so /usr/lib/x86_64-linux-gnu/libQt5DBus.so /usr/lib/x86_64-linux-gnu/libQt5Core.so /usr/lib/x86_64-linux-gnu/libGL.so -lpthread
/usr/bin/ld: objects/documentview.o: in function `qpdfview::DocumentView::printUsingCUPS(QPrinter*, qpdfview::PrintOptions const&, int, int)':
documentview.cpp:(.text+0xb56a): undefined reference to `cupsGetDests'
/usr/bin/ld: documentview.cpp:(.text+0xb5ab): undefined reference to `cupsGetDest'
/usr/bin/ld: documentview.cpp:(.text+0xb65a): undefined reference to `cupsAddOption'
/usr/bin/ld: documentview.cpp:(.text+0xb769): undefined reference to `cupsAddOption'
/usr/bin/ld: documentview.cpp:(.text+0xb803): undefined reference to `cupsAddOption'
/usr/bin/ld: documentview.cpp:(.text+0xb88b): undefined reference to `cupsAddOption'
/usr/bin/ld: documentview.cpp:(.text+0xb8d3): undefined reference to `cupsAddOption'
/usr/bin/ld: documentview.cpp:(.text+0xb961): undefined reference to `cupsGetOption'
/usr/bin/ld: documentview.cpp:(.text+0xb9e7): undefined reference to `cupsGetOption'
/usr/bin/ld: documentview.cpp:(.text+0xba50): undefined reference to `cupsAddOption'
/usr/bin/ld: documentview.cpp:(.text+0xba90): undefined reference to `cupsGetOption'
/usr/bin/ld: documentview.cpp:(.text+0xbd1b): undefined reference to `cupsPrintFile'
/usr/bin/ld: documentview.cpp:(.text+0xbdd1): undefined reference to `cupsFreeDests'
/usr/bin/ld: documentview.cpp:(.text+0xbdde): undefined reference to `cupsFreeOptions'
/usr/bin/ld: documentview.cpp:(.text+0xbdfa): undefined reference to `cupsFreeDests'
/usr/bin/ld: documentview.cpp:(.text+0xbe07): undefined reference to `cupsFreeOptions'
/usr/bin/ld: documentview.cpp:(.text+0xbe69): undefined reference to `cupsGetPPD'
/usr/bin/ld: documentview.cpp:(.text+0xbe7f): undefined reference to `ppdOpenFile'
/usr/bin/ld: documentview.cpp:(.text+0xbe9c): undefined reference to `ppdFindOption'
/usr/bin/ld: documentview.cpp:(.text+0xbf0a): undefined reference to `cupsAddOption'
/usr/bin/ld: documentview.cpp:(.text+0xbf17): undefined reference to `ppdClose'
/usr/bin/ld: documentview.cpp:(.text+0xbf81): undefined reference to `cupsAddOption'
/usr/bin/ld: documentview.cpp:(.text+0xbfa5): undefined reference to `cupsAddOption'
/usr/bin/ld: documentview.cpp:(.text+0xbfcd): undefined reference to `cupsAddOption'
/usr/bin/ld: documentview.cpp:(.text+0xc099): undefined reference to `cupsAddOption'
/usr/bin/ld: documentview.cpp:(.text+0xc29d): undefined reference to `cupsAddOption'
/usr/bin/ld: objects/documentview.o:documentview.cpp:(.text+0xc2c5): more undefined references to `cupsAddOption' follow
/usr/bin/ld: objects/documentview.o: in function `qpdfview::DocumentView::printUsingCUPS(QPrinter*, qpdfview::PrintOptions const&, int, int)':
documentview.cpp:(.text+0xc518): undefined reference to `cupsLastErrorString'
/usr/bin/ld: documentview.cpp:(.text+0xc657): undefined reference to `cupsLastErrorString'
/usr/bin/ld: documentview.cpp:(.text+0xc6e1): undefined reference to `cupsFreeDests'
/usr/bin/ld: documentview.cpp:(.text+0xc788): undefined reference to `cupsAddOption'
/usr/bin/ld: objects/documentview.o: in function `qpdfview::DocumentView::printUsingCUPS(QPrinter*, qpdfview::PrintOptions const&, int, int) [clone .cold]':
documentview.cpp:(.text.unlikely+0x955): undefined reference to `ppdClose'
collect2: error: ld returned 1 exit status
make[1]: *** [Makefile.application:358: qpdfview] Error 1
make[1]: Leaving directory 'qpdfview-0.5'
make: *** [Makefile:164: sub-application-pro-make_first-ordered] Error 2
De acordo com esta resposta parece que o problema está no código fonte. Mas eu não tenho certeza. Pode ser que eu tenha perdido alguma dependência adicional. Continuaremos investigando, mas provavelmente alguém já compilou este programa com sucesso?