Bug 114551 - graphics/poppler-qt4 is unusable
Summary: graphics/poppler-qt4 is unusable
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-gnome (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-07-13 13:00 UTC by Sven Gaerner
Modified: 2007-07-13 15:00 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sven Gaerner 2007-07-13 13:00:09 UTC
poppler-qt4 is unusable because linking against libpoppler-qt4.so results in a link error.
/usr/local/lib/libpoppler-qt4.so: undefined reference to `ArthurOutputDev::startDoc(XRef*)'
/usr/local/lib/libpoppler-qt4.so: undefined reference to `ArthurOutputDev::~ArthurOutputDev()'
/usr/local/lib/libpoppler-qt4.so: undefined reference to `ArthurOutputDev::ArthurOutputDev(QPainter*)'

This error is caused by a poppler configuration.
The above mentioned Arthur rendering backend is only build if QT4 support is requested. But unfortunately the implementation is located within the poppler/ subdirectory and is linked into libpoppler.so. This is no problem if the whole library is build but the poppler-qt4 port just builds the QT4 support forgetting to link the Arthur backend object into the library. That means the resulting libpoppler-qt4.so references the Arthur backend which is not available.

Fix: 

Build the Arthur backend located in the poppler/ subdirectory and link it into the libpoppler-qt4.so.

I think this is more a workaround than a solution. It would be better if the poppler developers would link the Arthur backend into the libpoppler-qt4.so library.
How-To-Repeat: Link against libpoppler-qt4 and reference some class.

For example:

#include <poppler-qt4.h>

int main(int argc, char **argv) {

  Poppler::Document *doc = NULL;

  doc = Poppler::Document::load("/path/to/pdf_file.pdf");

  delete doc;

  return 0;
}

And the QMake file:

TARGET      = poppler-test
TEMPLATE    = app
QT         += core gui xml

INCLUDEPATH += /usr/local/include/poppler/qt4
LIBS        += -lpoppler-qt4

CONFIG(debug, debug|release) {
  TARGET = pdfviewd
}
else {
  TARGET = pdfview
}

MOC_DIR      = .moc
OBJECTS_DIR  = .obj

SOURCES += poppler-test.cc

Set environment variable QMAKESPEC to freebsd-g++
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2007-07-13 13:43:43 UTC
Responsible Changed
From-To: freebsd-ports-bugs->gnome

Over to maintainer
Comment 2 dfilter service freebsd_committer freebsd_triage 2007-07-13 14:54:48 UTC
ahze        2007-07-13 13:54:42 UTC

  FreeBSD ports repository

  Modified files:
    graphics/poppler     Makefile 
    graphics/poppler-qt4 Makefile 
  Removed files:
    graphics/poppler/files patch-qt4_src_Makefile.in 
  Log:
  Don't link to libpoppler from graphics/poppler since it doesn't contain required Arthur backend. Instead build libpoppler with poppler-qt4
  
  PR:             ports/114551
  Reported by:            Sven Gaerner <sgaerner@gmx.net>
  
  Revision  Changes    Path
  1.2       +1 -1      ports/graphics/poppler-qt4/Makefile
  1.27      +19 -7     ports/graphics/poppler/Makefile
  1.2       +0 -34     ports/graphics/poppler/files/patch-qt4_src_Makefile.in (dead)
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 3 Michael Johnson freebsd_committer freebsd_triage 2007-07-13 14:55:30 UTC
State Changed
From-To: open->closed

Fixed,, Thanks!