summaryrefslogtreecommitdiffstats
path: root/ham/tqsl/tqsl.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'ham/tqsl/tqsl.SlackBuild')
-rw-r--r--ham/tqsl/tqsl.SlackBuild69
1 files changed, 35 insertions, 34 deletions
diff --git a/ham/tqsl/tqsl.SlackBuild b/ham/tqsl/tqsl.SlackBuild
index 17c8bcb0a7..749989221d 100644
--- a/ham/tqsl/tqsl.SlackBuild
+++ b/ham/tqsl/tqsl.SlackBuild
@@ -1,29 +1,34 @@
-#!/bin/sh
+#!/bin/bash
# Slackbuild for tqsl
# Written by JK Wood <joshuakwood@gmail.com>
-
-# Slackbuild is released under the Dog-on-Fire License:
-# If use of this script causes your dog to catch on fire,
-# you agree to send me five dollars. Or a picture
-# of the dog on fire.
-# Otherwise, you're on your own. I've tested the script
-# on my own computer, and it hasn't broken anything.
-# So if it does it on your computer, that falls in
-# the realm of "Not my problem."
+# Brian Cox 2024 <hamslackbuild@comcast.net>
#
-# Of course, if you'll send a bug report to the above
-# email address, I may be able to see what you did
-# wrong and prevent it from happening in the future.
-# In which case, I may just send YOU five dollars.
-
-# Oh, and feel free to copy it and modify it as you
-# see fit. Or as I see fit. Or as I fit. Although
-# that is unlikely, as I am rather tall.
+# All rights reserved.
+#
+# Redistribution and use of this script, with or without modification, is
+# permitted provided that the following conditions are met:
+#
+# 1. Redistributions of this script must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ''AS IS'' AND ANY EXPRESS OR IMPLIED
+# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=tqsl
-VERSION=${VERSION:-2.4.7}
+VERSION=${VERSION:-2.7.3}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -33,7 +38,11 @@ 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}
@@ -47,6 +56,9 @@ elif [ "$ARCH" = "i686" ]; then
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
+elif [ "$ARCH" = "aarch64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
else
SLKCFLAGS="-O2"
LIBDIRSUFFIX=""
@@ -71,6 +83,7 @@ cmake \
-DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \
-DCMAKE_INSTALL_PREFIX=/usr \
+ -DCMAKE_INSTALL_MANDIR=man \
-DCMAKE_BUILD_TYPE=Release .
make
@@ -79,20 +92,8 @@ make install DESTDIR=$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
-
-# Fix hardcoded man page path >:(
-mv $PKG/usr/share/man $PKG/usr/man
-
+# Gzip man pages
find $PKG/usr/man -type f -exec gzip -9 {} \;
-for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
-
-# Fix weirdness wtih LIB directory
-if [ "$LIBDIRSUFFIX" = "64" ]; then
- mv $PKG/usr/lib $PKG/usr/lib${LIBDIRSUFFIX}
-fi
-
-mkdir -p $PKG/usr/share/applications
-install -m 644 $CWD/tqsl.desktop $PKG/usr/share/applications
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a AUTHORS.txt INSTALL LICENSE.txt README $PKG/usr/doc/$PRGNAM-$VERSION
@@ -105,4 +106,4 @@ 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:-tgz}
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE