summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-07-31 19:57:25 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-07-31 19:57:25 +0000
commit1f42a5796ab9393d147b7478daa31b42ce07826d (patch)
treef125b3104dc7f781bcfc3ee57cf952deb6a00b2d
parentf894196abacde45a82e552c1bc6e5cfdf5b75c4b (diff)
downloadtdegraphics-1f42a5796ab9393d147b7478daa31b42ce07826d.tar.gz
tdegraphics-1f42a5796ab9393d147b7478daa31b42ce07826d.zip
Fix kdegraphics poppler >=0.16 detection
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegraphics@1244223 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
-rw-r--r--config.h.cmake3
-rw-r--r--kfile-plugins/dependencies/poppler-tqt/ConfigureChecks.cmake4
-rw-r--r--kfile-plugins/dependencies/poppler-tqt/poppler-document.cc3
3 files changed, 5 insertions, 5 deletions
diff --git a/config.h.cmake b/config.h.cmake
index d410947c..083047f1 100644
--- a/config.h.cmake
+++ b/config.h.cmake
@@ -1,5 +1,8 @@
#cmakedefine VERSION "@VERSION@"
+// poppler-tqt
+#cmakedefine HAVE_POPPLER_016
+
// kpdf, kdvi
#cmakedefine HAVE_FREETYPE 1
diff --git a/kfile-plugins/dependencies/poppler-tqt/ConfigureChecks.cmake b/kfile-plugins/dependencies/poppler-tqt/ConfigureChecks.cmake
index a021744c..2401f44d 100644
--- a/kfile-plugins/dependencies/poppler-tqt/ConfigureChecks.cmake
+++ b/kfile-plugins/dependencies/poppler-tqt/ConfigureChecks.cmake
@@ -6,7 +6,3 @@ check_cxx_source_compiles("
int main(int, char**) { int a; int b; PSOutputDev *psOut = new PSOutputDev(\"test\", (PDFDoc*)0, (XRef*)0, (Catalog*)0, NULL, 0, 0, psModePS, a, b); } "
HAVE_POPPLER_016 )
tde_restore( CMAKE_REQUIRED_INCLUDES CMAKE_REQUIRED_LIBRARIES )
-
-if( HAVE_POPPLER_016 )
- set( POPPLER_016 1 )
-endif( )
diff --git a/kfile-plugins/dependencies/poppler-tqt/poppler-document.cc b/kfile-plugins/dependencies/poppler-tqt/poppler-document.cc
index 93d5a49c..5fe6ea28 100644
--- a/kfile-plugins/dependencies/poppler-tqt/poppler-document.cc
+++ b/kfile-plugins/dependencies/poppler-tqt/poppler-document.cc
@@ -19,6 +19,7 @@
* Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
*/
+#include <config.h>
#include <poppler-qt.h>
#include <tqfile.h>
#include <GlobalParams.h>
@@ -316,7 +317,7 @@ bool Document::print(const TQString &fileName, TQValueList<int> pageList, double
bool Document::print(const TQString &file, TQValueList<int> pageList, double hDPI, double vDPI, int rotate, int paperWidth, int paperHeight)
{
-#ifdef POPPLER_016
+#ifdef HAVE_POPPLER_016
PSOutputDev *psOut = new PSOutputDev(file.latin1(), &(data->doc), data->doc.getXRef(), data->doc.getCatalog(), NULL, 1, data->doc.getNumPages(), psModePS, paperWidth, paperHeight);
#else
PSOutputDev *psOut = new PSOutputDev(file.latin1(), data->doc.getXRef(), data->doc.getCatalog(), NULL, 1, data->doc.getNumPages(), psModePS, paperWidth, paperHeight);