From 86fa9277e7997710144af890413780bed55e3a4a Mon Sep 17 00:00:00 2001 From: John Cupitt Date: Thu, 24 Dec 2020 05:44:07 +0000 Subject: [PATCH] note PDFium build in README --- README.md | 27 +++++++++++++++++++++++++-- 1 file changed, 25 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 2e48c31f..b90bc5e7 100644 --- a/README.md +++ b/README.md @@ -162,8 +162,31 @@ via imagemagick instead. ### PDFium -If present, libvips will attempt to load PDFs via PDFium. This library must be -packaged by https://github.com/jcupitt/docker-builds/tree/master/pdfium +If present, libvips will attempt to load PDFs with PDFium. Download the +prebuilt pdfium binary from: + + https://github.com/bblanchon/pdfium-binaries + +Untar to the libvips install prefix, for example: + + cd ~/vips + tar xf ~/pdfium-linux.tgz + +Create a `pdfium.pc` like this (update the version number): + + VIPSHOME=/home/john/vips + cat > $VIPSHOME/lib/pkgconfig/pdfium.pc << EOF + prefix=$VIPSHOME + exec_prefix=\${prefix} + libdir=\${exec_prefix}/lib + includedir=\${prefix}/include + Name: pdfium + Description: pdfium + Version: 4290 + Requires: + Libs: -L\${libdir} -lpdfium + Cflags: -I\${includedir} + EOF If PDFium is not detected, libvips will look for poppler-glib instead.