From abd57e6f4300dd10e13930076f7d11ca3f08c2cd Mon Sep 17 00:00:00 2001 From: Nick Bowler Subject: [PATCH] Add Gentoo font paths to default search dir. This allows Xpdf to automatically find the required type-1 fonts on Gentoo. The font paths can also be set in xpdfrc, but this approach is more robust as the user's xpdfrc overrides the system-wide one. The newly added paths respect datarootdir to better support prefixed installations. --- xpdf/GlobalParams.cc | 2 ++ xpdf/Makefile.in | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/xpdf/GlobalParams.cc b/xpdf/GlobalParams.cc index ea7e9fd9d142..19e04114adb4 100644 --- a/xpdf/GlobalParams.cc +++ b/xpdf/GlobalParams.cc @@ -120,6 +120,8 @@ static const char *displayFontDirs[] = { }; #else static const char *displayFontDirs[] = { + DATAROOTDIR "/fonts/urw-fonts", + DATAROOTDIR "/fonts/Type1", "/usr/share/ghostscript/fonts", "/usr/local/share/ghostscript/fonts", "/usr/share/fonts/default/Type1", diff --git a/xpdf/Makefile.in b/xpdf/Makefile.in index de3e6766e60a..d7118b7053a1 100644 --- a/xpdf/Makefile.in +++ b/xpdf/Makefile.in @@ -9,6 +9,7 @@ SHELL = /bin/sh prefix = @prefix@ +datarootdir = @datarootdir@ srcdir = @srcdir@ VPATH = @srcdir@ @@ -19,7 +20,7 @@ FOFILIBDIR = ../fofi SPLASHSRCDIR = $(srcdir)/../splash SPLASHLIBDIR = ../splash -CXXFLAGS = @CXXFLAGS@ @DEFS@ -I.. -I$(srcdir)/.. -I$(GOOSRCDIR) -I$(FOFISRCDIR) -I$(SPLASHSRCDIR) -I$(srcdir) @freetype2_CFLAGS@ @Sgm_CFLAGS@ @Xm_CFLAGS@ @Xt_CFLAGS@ @Xp_CFLAGS@ @Xext_CFLAGS@ @Xpm_CFLAGS@ @libpng_CFLAGS@ @libpaper_CFLAGS@ @X_CFLAGS@ @EXTRA_CFLAGS@ +CXXFLAGS = @CXXFLAGS@ @DEFS@ -DDATAROOTDIR=\"$(datarootdir)\" -I.. -I$(srcdir)/.. -I$(GOOSRCDIR) -I$(FOFISRCDIR) -I$(SPLASHSRCDIR) -I$(srcdir) @freetype2_CFLAGS@ @Sgm_CFLAGS@ @Xm_CFLAGS@ @Xt_CFLAGS@ @Xp_CFLAGS@ @Xext_CFLAGS@ @Xpm_CFLAGS@ @libpng_CFLAGS@ @libpaper_CFLAGS@ @X_CFLAGS@ @EXTRA_CFLAGS@ LDFLAGS = @LDFLAGS@ -- 2.24.1