From 8b997baa3eeb1b3c7692799b8c65547df815906f Mon Sep 17 00:00:00 2001 From: Tom Yan Date: Mon, 9 Jul 2018 22:18:39 +0800 Subject: [PATCH] poppler: make use of fontconfig The CMakeLists.txt shipped by upstream assumes that fontconfig is not available in Android, which is not the case in Termux. Enable the use of fontconfig with cached value. Also remove the patch that matters only when poppler is built without fontconfig support. --- packages/poppler/build.sh | 3 ++- .../poppler/poppler-GlobalParams.cc.patch | 20 ------------------- 2 files changed, 2 insertions(+), 21 deletions(-) delete mode 100644 packages/poppler/poppler-GlobalParams.cc.patch diff --git a/packages/poppler/build.sh b/packages/poppler/build.sh index 6d3586c2c..adf8962d2 100644 --- a/packages/poppler/build.sh +++ b/packages/poppler/build.sh @@ -1,7 +1,7 @@ TERMUX_PKG_HOMEPAGE=https://poppler.freedesktop.org/ TERMUX_PKG_DESCRIPTION="PDF rendering library" TERMUX_PKG_VERSION=0.66.0 -TERMUX_PKG_REVISION=1 +TERMUX_PKG_REVISION=2 TERMUX_PKG_SHA256=2c096431adfb74bc2f53be466889b7646e1b599f28fa036094f3f7235cc9eae7 TERMUX_PKG_SRCURL=https://poppler.freedesktop.org/poppler-${TERMUX_PKG_VERSION}.tar.xz # libcairo and littlecms is used by pdftocairo: @@ -10,4 +10,5 @@ TERMUX_PKG_DEPENDS="fontconfig, libcairo, libpng, libjpeg-turbo, libtiff, little TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" -DENABLE_GLIB=OFF -DENABLE_XPDF_HEADERS=ON +-DFONT_CONFIGURATION=fontconfig " diff --git a/packages/poppler/poppler-GlobalParams.cc.patch b/packages/poppler/poppler-GlobalParams.cc.patch deleted file mode 100644 index 89cda8f64..000000000 --- a/packages/poppler/poppler-GlobalParams.cc.patch +++ /dev/null @@ -1,20 +0,0 @@ -diff -uNr poppler-0.65.0/poppler/GlobalParams.cc poppler-0.65.0.mod/poppler/GlobalParams.cc ---- poppler-0.65.0/poppler/GlobalParams.cc 2018-05-19 18:05:25.000000000 +0300 -+++ poppler-0.65.0.mod/poppler/GlobalParams.cc 2018-06-19 16:04:51.997503128 +0300 -@@ -1239,11 +1239,11 @@ - }; - - static const char *displayFontDirs[] = { -- "/usr/share/ghostscript/fonts", -- "/usr/local/share/ghostscript/fonts", -- "/usr/share/fonts/default/Type1", -- "/usr/share/fonts/default/ghostscript", -- "/usr/share/fonts/type1/gsfonts", -+ "@TERMUX_PREFIX@/share/ghostscript/fonts", -+ "@TERMUX_PREFIX@/local/share/ghostscript/fonts", -+ "@TERMUX_PREFIX@/share/fonts/default/Type1", -+ "@TERMUX_PREFIX@/share/fonts/default/ghostscript", -+ "@TERMUX_PREFIX@/share/fonts/type1/gsfonts", - NULL - }; -