summaryrefslogtreecommitdiffstats
path: root/office/wordtsar/wordtsar.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'office/wordtsar/wordtsar.SlackBuild')
-rw-r--r--office/wordtsar/wordtsar.SlackBuild82
1 files changed, 82 insertions, 0 deletions
diff --git a/office/wordtsar/wordtsar.SlackBuild b/office/wordtsar/wordtsar.SlackBuild
new file mode 100644
index 0000000000..2508308004
--- /dev/null
+++ b/office/wordtsar/wordtsar.SlackBuild
@@ -0,0 +1,82 @@
+#!/bin/bash
+
+# Slackware build script for wordtsar
+
+# Written by B. Watson (urchlay@slackware.uk)
+
+# Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details.
+
+# Note: building.txt appears to be horribly out of date; it refers
+# to wxWidgets and CodeLite... but this is a Qt app, built with
+# qmake. *shrug*.
+
+cd $(dirname $0) ; CWD=$(pwd)
+
+PRGNAM=wordtsar
+SRCNAM=WordTsar
+VERSION=${VERSION:-0.3.719}
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
+
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) ARCH=i586 ;;
+ arm*) ARCH=arm ;;
+ *) ARCH=$( uname -m ) ;;
+ esac
+fi
+
+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}
+
+# no flags or libdir stuffs here, qmake knows what to do.
+
+set -e
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $SRCNAM-$VERSION-src
+unzip $CWD/$SRCNAM-$VERSION-src.zip
+cd $SRCNAM-$VERSION-src
+chown -R root:root .
+find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} \+ -o \
+ \! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} \+
+
+# weirdness, refers to ../src/<whatever>
+sed -i.bak 's,\.\./,,g' *.pro
+
+qmake-qt5
+make
+
+# no 'make install'.
+mkdir -p $PKG/usr/{bin,share/{applications,pixmaps}}
+install -s -m0755 $SRCNAM $PKG/usr/bin
+install -m0644 linuxdeploy/$SRCNAM.desktop $PKG/usr/share/applications/$SRCNAM.desktop
+
+for px in 16 22 32 48 64 128; do
+ sz=${px}x${px}
+ dir=$PKG/usr/share/icons/hicolor/$sz/apps
+ mkdir -p $dir
+ convert -resize $sz linuxdeploy/$PRGNAM.png $dir/$PRGNAM.png
+done
+ln -s ../icons/hicolor/48x48/apps/$PRGNAM.png $PKG/usr/share/pixmaps/$PRGNAM.png
+
+PKGDOC=$PKG/usr/doc/$PRGNAM-$VERSION
+mkdir -p $PKGDOC
+cp -a LICENSE* implemented.xlsx $PKGDOC
+cat $CWD/$PRGNAM.SlackBuild > $PKGDOC/$PRGNAM.SlackBuild
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+cat $CWD/doinst.sh > $PKG/install/doinst.sh
+
+cd $PKG
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE