summaryrefslogtreecommitdiffstats
path: root/office/zathura
diff options
context:
space:
mode:
Diffstat (limited to 'office/zathura')
-rw-r--r--office/zathura/README9
-rw-r--r--office/zathura/fix_completion.diff33
-rw-r--r--office/zathura/man/zathura.117
-rw-r--r--office/zathura/man/zathurarc.523
-rw-r--r--office/zathura/slack-desc2
-rw-r--r--office/zathura/zathura.SlackBuild98
-rw-r--r--office/zathura/zathura.info10
7 files changed, 139 insertions, 53 deletions
diff --git a/office/zathura/README b/office/zathura/README
index bedfe1ddc0..e13e1e811a 100644
--- a/office/zathura/README
+++ b/office/zathura/README
@@ -7,7 +7,10 @@ saving interface as well as an easy usage that mainly focuses on
keyboard interaction.
This build includes the zathura core and the zathura-pdf-poppler
-plugin.
+plugin, by default. If you don't want zathura-pdf-poppler, you can
+run the script with POPPLER=no set in the environment. In this case,
+zathura will be useless until you install at least one of the plugins
+listed below.
Other plugins exist to support other file types:
@@ -24,3 +27,7 @@ Documentation on zathura's synctex support is poor; for some hints on
using synctex with zathura, see:
http://www.math.cmu.edu/~gautam/sj/blog/20140310-zathura-fsearch.html
+
+Note: This is not the latest version of zathura; it is the latest
+version that will build on Slackware 15.0. Don't expect this to be
+upgraded until after the next Slackware release.
diff --git a/office/zathura/fix_completion.diff b/office/zathura/fix_completion.diff
new file mode 100644
index 0000000000..1e12927fa4
--- /dev/null
+++ b/office/zathura/fix_completion.diff
@@ -0,0 +1,33 @@
+diff -Naur zathura-0.5.1/data/bash-completion.in zathura-0.5.1.patched/data/bash-completion.in
+--- zathura-0.5.1/data/bash-completion.in 2022-09-08 18:17:27.000000000 -0400
++++ zathura-0.5.1.patched/data/bash-completion.in 2022-11-14 14:00:24.545471924 -0500
+@@ -4,6 +4,7 @@
+
+ local EXTS=""
+ for PLUGIN in @PLUGINDIR@/lib*.so; do
++ PLUGIN="$( realpath "$PLUGIN" )"
+ case ${PLUGIN##*/} in
+ libpdf-poppler.so)
+ EXTS="$EXTS|pdf|PDF"
+diff -Naur zathura-0.5.1/data/fish-completion.in zathura-0.5.1.patched/data/fish-completion.in
+--- zathura-0.5.1/data/fish-completion.in 2022-09-08 18:17:27.000000000 -0400
++++ zathura-0.5.1.patched/data/fish-completion.in 2022-11-14 14:02:01.958086580 -0500
+@@ -1,6 +1,7 @@
+ # Complete custom suffix based on libraries installed
+ function __fish_complete_zathura
+ for plugin in @PLUGINDIR@/*.so
++ set plugin (realpath $plugin)
+ switch (basename $plugin)
+ case libpdf-poppler.so
+ __fish_complete_suffix .pdf
+diff -Naur zathura-0.5.1/data/zsh-completion.in zathura-0.5.1.patched/data/zsh-completion.in
+--- zathura-0.5.1/data/zsh-completion.in 2022-09-08 18:17:27.000000000 -0400
++++ zathura-0.5.1.patched/data/zsh-completion.in 2022-11-14 14:00:17.978363071 -0500
+@@ -27,6 +27,7 @@
+ local PLUGIN
+ local -a exts
+ for PLUGIN in @PLUGINDIR@/lib*.so; do
++ PLUGIN="$( realpath "$PLUGIN" )"
+ case ${PLUGIN##*/} in
+ libpdf-poppler.so)
+ exts+=( pdf PDF )
diff --git a/office/zathura/man/zathura.1 b/office/zathura/man/zathura.1
index 5df172841e..dd5b216ebb 100644
--- a/office/zathura/man/zathura.1
+++ b/office/zathura/man/zathura.1
@@ -1,8 +1,5 @@
.\" Man page generated from reStructuredText.
.
-.TH "ZATHURA" "1" "2021-07-14" "0.4.8" "zathura"
-.SH NAME
-zathura \- a document viewer
.
.nr rst2man-indent-level 0
.
@@ -30,6 +27,9 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
+.TH "ZATHURA" "1" "2022-09-08" "0.5.1" "zathura"
+.SH NAME
+zathura \- a document viewer
.SH SYNOPSIS
.sp
zathura [\-e XID] [\-c PATH] [\-d PATH] [\-p PATH] [\-w PASSWORD] [\-P NUMBER]
@@ -88,13 +88,13 @@ correct file open or does not exist, no new instance will be spanned.
.BI \-\-mode\fB= mode
Start in a non\-default mode
.TP
-.B \-\-fork
+.B \-\-fork
Fork into background
.TP
-.B \-\-version
+.B \-\-version
Display version string and exit
.TP
-.B \-\-help
+.B \-\-help
Display help and exit
.UNINDENT
.SH MOUSE AND KEY BINDINGS
@@ -328,7 +328,8 @@ List bookmarks
Close document
.TP
.B exec
-Execute an external command
+Execute an external command. \fB$FILE\fP expands to the current document path,
+and \fB$PAGE\fP to the current page number
.TP
.B info
Show document information
@@ -424,6 +425,6 @@ appear, if overlay\-scrollbar is enabled in GTK_MODULES.
.SH AUTHOR
pwmt.org
.SH COPYRIGHT
-2009-2021, pwmt.org
+2009-2018, pwmt.org
.\" Generated by docutils manpage writer.
.
diff --git a/office/zathura/man/zathurarc.5 b/office/zathura/man/zathurarc.5
index bd6d64daad..e165c7cd58 100644
--- a/office/zathura/man/zathurarc.5
+++ b/office/zathura/man/zathurarc.5
@@ -1,8 +1,5 @@
.\" Man page generated from reStructuredText.
.
-.TH "ZATHURARC" "5" "2021-07-14" "0.4.8" "zathura"
-.SH NAME
-zathurarc \- zathura configuration file
.
.nr rst2man-indent-level 0
.
@@ -30,6 +27,9 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
+.TH "ZATHURARC" "5" "2022-09-08" "0.5.1" "zathura"
+.SH NAME
+zathurarc \- zathura configuration file
.SH SYNOPSIS
.sp
/etc/zathurarc, $XDG_CONFIG_HOME/zathura/zathurarc
@@ -338,7 +338,8 @@ Display link target.
.IP \(bu 2
\fBexec\fP:
.sp
-Execute an external command.
+Execute an external command. \fB$FILE\fP expands to the current document path,
+and \fB$PAGE\fP to the current page number.
.IP \(bu 2
\fBfocus_inputbar\fP
.sp
@@ -1207,6 +1208,15 @@ Value type: Boolean
Default value: false
.UNINDENT
.TP
+.B \fIstatusbar\-page\-percent\fP
+Display (current page / total pages) as a percent in the statusbar.
+.INDENT 7.0
+.IP \(bu 2
+Value type: Boolean
+.IP \(bu 2
+Default value: false
+.UNINDENT
+.TP
.B \fIstatusbar\-home\-tilde\fP
Display a short version of the file path, which replaces $HOME with ~, in the statusbar.
.INDENT 7.0
@@ -1362,6 +1372,9 @@ printing
bookmarks and history
.UNINDENT
.sp
+The strict sandbox mode is still experimental with some libc implementations.
+Currently supported and tested libc implementations: glibc
+.sp
No feature regressions are expected when using normal sandbox mode.
.sp
When running under WSL, the default is "none" since seccomp is not supported in
@@ -1392,6 +1405,6 @@ zathura(1)
.SH AUTHOR
pwmt.org
.SH COPYRIGHT
-2009-2021, pwmt.org
+2009-2018, pwmt.org
.\" Generated by docutils manpage writer.
.
diff --git a/office/zathura/slack-desc b/office/zathura/slack-desc
index 871551a92b..ee6695b0b2 100644
--- a/office/zathura/slack-desc
+++ b/office/zathura/slack-desc
@@ -14,6 +14,6 @@ zathura: zathura is an application that provides a minimalistic and space
zathura: saving interface as well as an easy usage that mainly focuses on
zathura: keyboard interaction.
zathura:
-zathura:
+zathura: This package @INCLUDES@ the zathura-pdf-poppler plugin.
zathura:
zathura:
diff --git a/office/zathura/zathura.SlackBuild b/office/zathura/zathura.SlackBuild
index 61c24d49df..4f5130e113 100644
--- a/office/zathura/zathura.SlackBuild
+++ b/office/zathura/zathura.SlackBuild
@@ -23,6 +23,20 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+# 20240319 bkw: update for v0.5.4 and zathura-pdf-poppler 0.3.2.
+# These are the last versions that will build on Slackware 15.0
+# due to newer versions needing a newer pango.
+
+# 20230105 bkw: update for v0.5.1 and zathura-pdf-poppler 0.3.1.
+
+# 20221114 bkw:
+# - update for v0.5.1. zathura-pdf-poppler is still 0.3.0.
+# - fix bash/zsh/fish completion.
+# - change symlink name from pdf.so to libpdf.so (helps with completion).
+# - make zathura-pdf-poppler optional.
+# - update prebuilt man pages.
+# - stop installing duplicate man pages if Sphinx is installed.
+
# 20210801 bkw:
# - update for v0.4.8 and -current. build uses meson now, so this script
# can no longer build old zathura versions.
@@ -32,7 +46,7 @@
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=zathura
-VERSION=${VERSION:-0.4.8}
+VERSION=${VERSION:-0.5.4}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
@@ -41,7 +55,7 @@ PKGTYPE=${PKGTYPE:-tgz}
# plugins. This build includes the default PDF plugin, without which zathura
# is completely useless.
PLUGIN=$PRGNAM-pdf-poppler
-PLUGINVER=${PLUGINVER:-0.3.0}
+PLUGINVER=${PLUGINVER:-0.3.2}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -90,6 +104,15 @@ tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
cd $PRGNAM-$VERSION
fixperms
+# 20240319 bkw: upstream decided we needed a newer meson, but this
+# builds just fine with our older one.
+sed -i '/meson_version/s,>=0\.61,>=0.59,' meson.build
+
+# 20221114 bkw: Maik Wagner and Alexander Verbovetsky reported that
+# fish and bash completion weren't working, due to the symlink I use
+# to switch between the PDF plugins. This patch should fix it.
+patch -p1 < $CWD/fix_completion.diff
+
mkdir build
cd build
CFLAGS="$SLKCFLAGS" \
@@ -107,8 +130,9 @@ cd build
DESTDIR=$PKG $NINJA install
cd ..
-# man pages taken from Debian. I did this to avoid a dependency
-# on Sphinx (and its tree of 13 deps).
+# man pages prebuilt on a Slackware box with Sphinx installed. I did
+# this to avoid a dependency on Sphinx (and its tree of 13 deps).
+rm -rf $PKG/usr/man # in case we had Sphinx already...
for i in $CWD/man/*.*; do
dest="$PKG/usr/man/man$( echo $i | sed 's,.*\.,,' )"
mkdir -p "$dest"
@@ -124,37 +148,45 @@ cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
# less easy to navigate).
cp -a doc/api $PKG/usr/doc/$PRGNAM-$VERSION
-# Now build the plugin.
-cd $TMP
-rm -rf $PLUGIN-$PLUGINVER
-tar xvf $CWD/$PLUGIN-$PLUGINVER.tar.gz
-cd $PLUGIN-$PLUGINVER
-fixperms
-
-export PKG_CONFIG_PATH=$PKG/usr/lib$LIBDIRSUFFIX/pkgconfig:$PKG_CONFIG_PATH
-
-mkdir build
-cd build
- CFLAGS="$SLKCFLAGS -I$PKG/usr/include" \
- CXXFLAGS="$SLKCFLAGS -I$PKG/usr/include" \
- meson .. \
- --buildtype=release \
- --infodir=/usr/info \
- --libdir=/usr/lib${LIBDIRSUFFIX} \
- --localstatedir=/var \
- --mandir=/usr/man \
- --prefix=/usr \
- --sysconfdir=/etc \
- -Dstrip=true \
- -Dplugindir=/usr/lib$LIBDIRSUFFIX/$PRGNAM/pdf
- "${NINJA:=ninja}"
- DESTDIR=$PKG $NINJA install
-cd ..
-
-ln -s pdf/libpdf-poppler.so $PKG/usr/lib$LIBDIRSUFFIX/$PRGNAM/pdf.so
+# Now build the plugin, unless the user disabled it.
+if [ "${POPPLER:-yes}" != "no" ]; then
+ INCLUDES="includes"
+ cd $TMP
+ rm -rf $PLUGIN-$PLUGINVER
+ tar xvf $CWD/$PLUGIN-$PLUGINVER.tar.gz
+ cd $PLUGIN-$PLUGINVER
+ fixperms
+ sed -i '/meson_version/s,>=0\.61,>=0.59,' meson.build
+
+ export PKG_CONFIG_PATH=$PKG/usr/lib$LIBDIRSUFFIX/pkgconfig:$PKG_CONFIG_PATH
+
+ mkdir build
+ cd build
+ CFLAGS="$SLKCFLAGS -I$PKG/usr/include" \
+ CXXFLAGS="$SLKCFLAGS -I$PKG/usr/include" \
+ meson .. \
+ --buildtype=release \
+ --infodir=/usr/info \
+ --libdir=/usr/lib${LIBDIRSUFFIX} \
+ --localstatedir=/var \
+ --mandir=/usr/man \
+ --prefix=/usr \
+ --sysconfdir=/etc \
+ -Dstrip=true \
+ -Dplugindir=/usr/lib$LIBDIRSUFFIX/$PRGNAM/pdf
+ "${NINJA:=ninja}"
+ DESTDIR=$PKG $NINJA install
+ cd ..
+
+ ln -s pdf/libpdf-poppler.so $PKG/usr/lib$LIBDIRSUFFIX/$PRGNAM/libpdf.so
+else
+ # if we don't include the plugin, we still want the empty plugin dir.
+ mkdir -p $PKG/usr/lib$LIBDIRSUFFIX/$PRGNAM
+ INCLUDES="DOES NOT include"
+fi
mkdir -p $PKG/install
-cat $CWD/slack-desc > $PKG/install/slack-desc
+sed "s,@INCLUDES@,$INCLUDES," $CWD/slack-desc > $PKG/install/slack-desc
cat $CWD/doinst.sh > $PKG/install/doinst.sh
cd $PKG
diff --git a/office/zathura/zathura.info b/office/zathura/zathura.info
index 70b665d13f..93f42cfaf2 100644
--- a/office/zathura/zathura.info
+++ b/office/zathura/zathura.info
@@ -1,10 +1,10 @@
PRGNAM="zathura"
-VERSION="0.4.8"
+VERSION="0.5.4"
HOMEPAGE="https://github.com/pwmt/zathura"
-DOWNLOAD="https://github.com/pwmt/zathura/archive/0.4.8/zathura-0.4.8.tar.gz \
- https://github.com/pwmt/zathura-pdf-poppler/archive/0.3.0/zathura-pdf-poppler-0.3.0.tar.gz"
-MD5SUM="ea5457f064bdcfb1fda1f6f27bafbeb7 \
- c500be47cfac0e76e81309cfa7847353"
+DOWNLOAD="https://github.com/pwmt/zathura/archive/0.5.4/zathura-0.5.4.tar.gz \
+ https://github.com/pwmt/zathura-pdf-poppler/archive/0.3.2/zathura-pdf-poppler-0.3.2.tar.gz"
+MD5SUM="a929f3366a46bb05d623c299276f414b \
+ 23422e7606b815e025f3654dc05c0a13"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="girara"