From 19e02c41c070c2ab056e563e3cc36453d286d2a8 Mon Sep 17 00:00:00 2001 From: D Woodfall Date: Tue, 16 May 2023 19:36:05 +0100 Subject: academic/finchtv: Fix ARCH section. Signed-off-by: bedlam --- academic/finchtv/finchtv.SlackBuild | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/academic/finchtv/finchtv.SlackBuild b/academic/finchtv/finchtv.SlackBuild index 8493e202c8..0a8f1321a9 100644 --- a/academic/finchtv/finchtv.SlackBuild +++ b/academic/finchtv/finchtv.SlackBuild @@ -31,7 +31,19 @@ TAG=${TAG:-_SBo} PKGTYPE=${PKGTYPE:-tgz} SRCVER=1_3_1 -ARCH=i386 # This will work on a stock Slackware64 as well. + +# 2023-05-16 DW: check for ARCH and kick wronguns +if [ -z "$ARCH" ]; then + case "$ARCH" in + i?86) ARCH=i586 ;; + *) ARCH=$( uname -m ) ;; + esac +fi + +if ! [ "$ARCH" = "x86_64" ] && ! [[ $ARCH =~ i?86 ]]; then + printf "\n$ARCH is not supported... \n" >/dev/stderr + exit 1 +fi # If the variable PRINT_PACKAGE_NAME is set, then this script will report what # the name of the created package would be, and then exit. This information @@ -60,7 +72,7 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; -install -D -m755 $PRGNAM $PKG/usr/bin/$PRGNAM +install -D -m 755 $PRGNAM $PKG/usr/bin/$PRGNAM 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 -- cgit v1.2.3-65-gdbad