diff options
author | B. Watson <yalhcru@gmail.com> | 2015-09-12 03:28:05 -0400 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2015-09-19 19:49:16 +0700 |
commit | 0917b24a71ef30f2c55fa7f705d6f9eb50bbda26 (patch) | |
tree | 189ff2efd6c4959f5750605423bf269ba37bef2f /office/fbpdf/fbpdf.SlackBuild | |
parent | 0e66746f97eb5c59f6102e0158065130984e6f5d (diff) | |
download | slackbuilds-0917b24a71ef30f2c55fa7f705d6f9eb50bbda26.tar.gz |
office/fbpdf: Fix build with mupdf-1.7a.
Diffstat (limited to 'office/fbpdf/fbpdf.SlackBuild')
-rw-r--r-- | office/fbpdf/fbpdf.SlackBuild | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/office/fbpdf/fbpdf.SlackBuild b/office/fbpdf/fbpdf.SlackBuild index 02891669f2..33b522be1a 100644 --- a/office/fbpdf/fbpdf.SlackBuild +++ b/office/fbpdf/fbpdf.SlackBuild @@ -10,7 +10,7 @@ PRGNAM=fbpdf VERSION=${VERSION:-20140822} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then @@ -57,9 +57,13 @@ find -L . \ # This patch has been sent upstream. In my opinion, fbpdf is needlessly # difficult to use without it. +# ...a year later, and upstream never responded to my email (not even to +# say "no"). It's staying here though. [ "${PRISTINE:-no}" != "yes" ] && \ patch -p1 < $CWD/navigation.diff +# mupdf API keeps changing + sed -i \ -e 's,-lmupdf -lmujs,`pkg-config --libs mupdf`,' \ -e 's,-lopenjpeg,-lopenjp2,' \ @@ -72,11 +76,16 @@ make ${PRGNAM}2 fbdjvu install -s -m0755 ${PRGNAM}2 $PKG/usr/bin install -s -m0755 fbdjvu $PKG/usr/bin -# autodetect mupdf. -pkg-config --exists mupdf && \ - make clean && \ - make $PRGNAM && \ +# autodetect mupdf, apply patch if needed. +if pkg-config --exists mupdf; then + MUPDFVER="$( pkg-config --modversion mupdf 2>/dev/null | \ + sed 's,^[0-9]*\.\([0-9][0-9]*\).*,\1,' )" + [ "$MUPDFVER" != "" -a "$MUPDFVER" -gt "6" ] && + patch -p1 < $CWD/mupdf-1.7a.diff + make clean + make $PRGNAM install -s -m0755 $PRGNAM $PKG/usr/bin +fi # man page written for this build. mkdir -p $PKG/usr/man/man1 |