Patches for pdfTeX / luaTeX / XeTeX Declare GlobalParams constructor without config file argument and skip reading a config file. from: Han The Thanh Peter Breitenlohner diff -ur -N xpdf-3.03.orig/xpdf/GlobalParams.cc xpdf-3.03/xpdf/GlobalParams.cc --- xpdf-3.03.orig/xpdf/GlobalParams.cc 2011-08-22 13:57:15.000000000 +0200 +++ xpdf-3.03/xpdf/GlobalParams.cc 2011-08-22 14:11:46.000000000 +0200 @@ -628,10 +628,15 @@ // parsing //------------------------------------------------------------------------ +#ifdef PDF_PARSER_ONLY +GlobalParams::GlobalParams() { + UnicodeMap *map; +#else GlobalParams::GlobalParams(char *cfgFileName) { UnicodeMap *map; GString *fileName; FILE *f; +#endif int i; #if MULTITHREADED @@ -782,6 +787,7 @@ map = new UnicodeMap("UCS-2", gTrue, &mapUCS2); residentUnicodeMaps->add(map->getEncodingName(), map); +#ifndef PDF_PARSER_ONLY // look for a user config file, then a system-wide config file f = NULL; fileName = NULL; @@ -819,6 +825,7 @@ delete fileName; fclose(f); } +#endif /* !PDF_PARSER_ONLY */ } void GlobalParams::createDefaultKeyBindings() { diff -ur -N xpdf-3.03.orig/xpdf/GlobalParams.h xpdf-3.03/xpdf/GlobalParams.h --- xpdf-3.03.orig/xpdf/GlobalParams.h 2011-08-15 23:08:53.000000000 +0200 +++ xpdf-3.03/xpdf/GlobalParams.h 2011-08-22 14:11:46.000000000 +0200 @@ -5,6 +5,9 @@ // Copyright 2001-2003 Glyph & Cog, LLC // //======================================================================== +// Modified for TeX Live by Peter Breitenlohner +// See top-level ChangeLog for a list of all modifications +//======================================================================== #ifndef GLOBALPARAMS_H #define GLOBALPARAMS_H @@ -171,9 +174,14 @@ class GlobalParams { public: +#ifdef PDF_PARSER_ONLY + // Initialize the global parameters without reading a config file. + GlobalParams(); +#else // Initialize the global parameters by attempting to read a config // file. GlobalParams(char *cfgFileName); +#endif ~GlobalParams();