summaryrefslogtreecommitdiffstats
path: root/office/vmd
diff options
context:
space:
mode:
Diffstat (limited to 'office/vmd')
-rw-r--r--office/vmd/README13
-rw-r--r--office/vmd/vmd.SlackBuild54
-rw-r--r--office/vmd/vmd.info6
3 files changed, 35 insertions, 38 deletions
diff --git a/office/vmd/README b/office/vmd/README
index d3404bf4f5..9c2e5bcd1f 100644
--- a/office/vmd/README
+++ b/office/vmd/README
@@ -1,10 +1,13 @@
vmd (Terminal Markdown Viewer)
Render markdown in a terminal! Why? Because although Markdown is still
-readable as-is, if you use Markdown a lot, it's nice to have something to
-render it with the proper formatting - with bold text and emphasis, etc.
+readable as-is, if you use Markdown a lot, it's nice to have something
+to render it with the proper formatting - with bold text and emphasis,
+etc.
-This package requires Markdown compiled with python3 support
+This version is patched to ignore img tags, which makes vmd fail to
+parse certain markdown documents.
-Also, this version is patched to ignore img tags, which make vmd fail
-parsing certain markdown documents.
+Note: this works great in the Linux console, konsole, xfce4-terminal,
+and kitty; acceptably well in xterm; and badly in rxvt-unicode. Your
+mileage may vary.
diff --git a/office/vmd/vmd.SlackBuild b/office/vmd/vmd.SlackBuild
index 20ad482a58..568e38eeb9 100644
--- a/office/vmd/vmd.SlackBuild
+++ b/office/vmd/vmd.SlackBuild
@@ -1,8 +1,9 @@
-#!/bin/sh
+#!/bin/bash
# Slackware build script for vmd
-# Copyright 2019 Ricardo J. Barberis <ricardo.barberis@gmail.com>
+# Copyright 2019 Ricardo J. Barberis
+# Copyright 2023 B. Watson
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -22,10 +23,18 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+# 20230807 bkw:
+# - take over maintenance.
+# - simplify script a bit (no package changes so BUILD=1 still).
+# - add note to README about supported terminals.
+
+cd $(dirname $0) ; CWD=$(pwd)
+
PRGNAM=vmd
VERSION=${VERSION:-0.1.1}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -35,24 +44,16 @@ if [ -z "$ARCH" ]; then
esac
fi
-CWD=$(pwd)
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
+ exit 0
+fi
+
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
-if [ "$ARCH" = "i586" ]; then
- SLKCFLAGS="-O2 -march=i586 -mtune=i686"
- LIBDIRSUFFIX=""
-elif [ "$ARCH" = "i686" ]; then
- SLKCFLAGS="-O2 -march=i686 -mtune=i686"
- LIBDIRSUFFIX=""
-elif [ "$ARCH" = "x86_64" ]; then
- SLKCFLAGS="-O2 -fPIC"
- LIBDIRSUFFIX="64"
-else
- SLKCFLAGS="-O2"
- LIBDIRSUFFIX=""
-fi
+# 20230807 bkw: No flags or libdirsuffix needed here.
set -e
@@ -63,11 +64,8 @@ rm -rf $PRGNAM-$VERSION
tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
cd $PRGNAM-$VERSION
chown -R root:root .
-find -L . \
- \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
- -o -perm 511 \) -exec chmod 755 {} \; -o \
- \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
- -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
+find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} + -o \
+ \! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} +
# Fix required Markdown version
sed -i -e 's/Markdown==2.6.8/Markdown>=2.6.8, <3/' requirements.txt setup.py
@@ -77,17 +75,13 @@ patch -p1 < $CWD/vmd.img.patch
python3 setup.py install --root=$PKG
-find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
- | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
-
-mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
-cp -a \
- LICENSE README.md requirements.txt \
- $PKG/usr/doc/$PRGNAM-$VERSION
-cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+PKGDOC=$PKG/usr/doc/$PRGNAM-$VERSION
+mkdir -p $PKGDOC
+cp -a LICENSE README.md requirements.txt $PKGDOC
+cat $CWD/$PRGNAM.SlackBuild > $PKGDOC/$PRGNAM.SlackBuild
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
cd $PKG
-/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE
diff --git a/office/vmd/vmd.info b/office/vmd/vmd.info
index 99926d8135..68916b4034 100644
--- a/office/vmd/vmd.info
+++ b/office/vmd/vmd.info
@@ -5,6 +5,6 @@ DOWNLOAD="https://github.com/cpascoe95/vmd/archive/v0.1.1/vmd-0.1.1.tar.gz"
MD5SUM="5dba1bf366780eb2e6bd1ce87e664517"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
-REQUIRES="python3 Markdown"
-MAINTAINER="Ricardo J. Barberis"
-EMAIL="ricardo.barberis@gmail.com"
+REQUIRES="Markdown"
+MAINTAINER="B. Watson"
+EMAIL="urchlay@slackware.uk"