summaryrefslogtreecommitdiff
path: root/sdext
diff options
context:
space:
mode:
authorPeter Foley <pefoley2@verizon.net>2012-11-10 15:16:14 -0500
committerTor Lillqvist <tml@iki.fi>2012-11-13 07:29:34 +0000
commita6e9bb4c7bad649cb44efaeef67fa18090348c53 (patch)
tree9988224bcfa074fd8665d19052fe145800474742 /sdext
parenta2b3ee4abf39e47037fa9adbf44a8742379098f7 (diff)
fdo#38878 upgrade xpdf to poppler
Change-Id: Ib908a3acba1faabeb411b4d1459968a362ee8029 Reviewed-on: https://gerrit.libreoffice.org/1036 Reviewed-by: Tor Lillqvist <tml@iki.fi> Tested-by: Tor Lillqvist <tml@iki.fi>
Diffstat (limited to 'sdext')
-rw-r--r--sdext/Executable_xpdfimport.mk5
-rw-r--r--sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx8
-rw-r--r--sdext/source/pdfimport/xpdfwrapper/wrapper_gpl.cxx27
3 files changed, 2 insertions, 38 deletions
diff --git a/sdext/Executable_xpdfimport.mk b/sdext/Executable_xpdfimport.mk
index f333ef9d6bce..e1e7db339935 100644
--- a/sdext/Executable_xpdfimport.mk
+++ b/sdext/Executable_xpdfimport.mk
@@ -34,13 +34,10 @@ $(eval $(call gb_Executable_use_packages,xpdfimport,\
$(eval $(call gb_Executable_use_externals,xpdfimport,\
poppler \
+ fontconfig \
zlib \
))
-$(eval $(call gb_Executable_set_include,xpdfimport,\
- $$(INCLUDE) \
-))
-
$(eval $(call gb_Executable_add_exception_objects,xpdfimport,\
sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl \
sdext/source/pdfimport/xpdfwrapper/pnghelper \
diff --git a/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx b/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx
index e5e48fc8a1a0..5d537e1e3fef 100644
--- a/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx
+++ b/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.hxx
@@ -34,9 +34,6 @@
#include "Link.h"
#include "Object.h"
#include "OutputDev.h"
-#ifndef SYSTEM_POPPLER
-# include "parseargs.h"
-#endif
#include "GlobalParams.h"
#include "PDFDoc.h"
@@ -52,16 +49,11 @@
class GfxPath;
class GfxFont;
class PDFDoc;
-#ifndef SYSTEM_POPPLER
-#define POPPLER_CHECK_VERSION(major,minor,micro) (0)
-typedef GString GooString;
-#else
#include <cpp/poppler-version.h>
#define POPPLER_CHECK_VERSION(major,minor,micro) \
(POPPLER_VERSION_MAJOR > (major) || \
(POPPLER_VERSION_MAJOR == (major) && POPPLER_VERSION_MINOR > (minor)) || \
(POPPLER_VERSION_MAJOR == (major) && POPPLER_VERSION_MINOR == (minor) && POPPLER_VERSION_MICRO >= (micro)))
-#endif
namespace pdfi
{
diff --git a/sdext/source/pdfimport/xpdfwrapper/wrapper_gpl.cxx b/sdext/source/pdfimport/xpdfwrapper/wrapper_gpl.cxx
index 3b9488565d56..fc6437b946d3 100644
--- a/sdext/source/pdfimport/xpdfwrapper/wrapper_gpl.cxx
+++ b/sdext/source/pdfimport/xpdfwrapper/wrapper_gpl.cxx
@@ -25,33 +25,12 @@
FILE* g_binary_out=stderr;
-#ifndef SYSTEM_POPPLER
-static char ownerPassword[33] = "\001";
-static char userPassword[33] = "\001";
-static char outputFile[256] = "\001";
-
-static ArgDesc argDesc[] = {
- {(char*)"-f", argString, outputFile, sizeof(outputFile),
- (char*)"output file for binary streams"},
- {(char*)"-opw", argString, ownerPassword, sizeof(ownerPassword),
- (char*)"owner password (for encrypted files)"},
- {(char*)"-upw", argString, userPassword, sizeof(userPassword),
- (char*)"user password (for encrypted files)"},
- {NULL, argString, NULL, 0, NULL }
-};
-#else
static const char *ownerPassword = "\001";
static const char *userPassword = "\001";
static const char *outputFile = "\001";
-#endif
int main(int argc, char **argv)
{
-#ifndef SYSTEM_POPPLER
- // parse args; initialize to defaults
- if( !parseArgs(argDesc, &argc, argv) )
- return 1;
-#else
int k = 0;
while (k < argc)
{
@@ -78,19 +57,15 @@ int main(int argc, char **argv)
}
++k;
}
-#endif
if( argc < 2 )
return 1;
// read config file
globalParams = new GlobalParams(
-#ifndef SYSTEM_POPPLER
- (char*)""
-#endif
);
globalParams->setErrQuiet(gTrue);
-#if !defined(SYSTEM_POPPLER) || defined(_MSC_VER)
+#if _MSC_VER
globalParams->setupBaseFonts(NULL);
#endif