aboutsummaryrefslogtreecommitdiff
path: root/network
diff options
context:
space:
mode:
authorPetar Petrov <slackalaxy@gmail.com>2023-09-15 20:15:03 +0900
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2023-09-17 00:10:19 +0700
commit36723eb09cee2d964d7c1d4baf6ff2fab926f314 (patch)
treead5f1d19b2fd333d7985f9ef27ae222eb886fac3 /network
parentc0b0862cd78a7391b7a45f7b795165609244da8a (diff)
network/viber: Script updates, new maintainer.
Signed-off-by: Andrew Clemons <andrew.clemons@gmail.com> Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'network')
-rw-r--r--network/viber/README10
-rw-r--r--network/viber/slack-desc10
-rw-r--r--network/viber/viber.SlackBuild54
-rw-r--r--network/viber/viber.info8
4 files changed, 31 insertions, 51 deletions
diff --git a/network/viber/README b/network/viber/README
index ad9e2bb24579..c7c9e2f81099 100644
--- a/network/viber/README
+++ b/network/viber/README
@@ -1,6 +1,8 @@
-Viber is a mobile application that allows you to make phone calls
-and send text messages to all other Viber users for free!
+Viber: Free and secure calls and messages to anyone, anywhere.
-Viber is available over WiFi or 3G.
+With Viber on your desktop, you can send and receive messages, enjoy
+group calls, create stickers, and more, as your devices seamlessly sync.
-There's only available the 64bit version.
+NOTE!
+Viber for Desktop is synced to your mobile account. To activate Viber
+for Desktop, you will need an active Viber account on your mobile phone.
diff --git a/network/viber/slack-desc b/network/viber/slack-desc
index 126fc3cb47e3..c37dccfc3e5c 100644
--- a/network/viber/slack-desc
+++ b/network/viber/slack-desc
@@ -6,13 +6,13 @@
# customary to leave one space after the ':' except on otherwise blank lines.
|-----handy-ruler------------------------------------------------------|
-viber: viber (mobile messaging application)
-viber:
-viber: Viber is a mobile application that allows you to make phone
-viber: calls and send text messages to all other Viber users for free!
-viber:
+viber: viber (Free and secure calls and messages)
viber:
+viber: With Viber on your desktop, you can send and receive messages,
+viber: enjoy group calls, create stickers, and more, as your devices
+viber: seamlessly sync.
viber:
+viber: https://www.viber.com/
viber:
viber:
viber:
diff --git a/network/viber/viber.SlackBuild b/network/viber/viber.SlackBuild
index 5ba2ac1a4a49..538a6427aad5 100644
--- a/network/viber/viber.SlackBuild
+++ b/network/viber/viber.SlackBuild
@@ -2,6 +2,7 @@
#
# Slackware build script for Viber
+# Copyright 2023 Petar Petrov, slackalaxy@gmail.com
# Copyright 2009-2017 Roberto Metere, Newcastle Upon Tyne, UK
# All rights reserved.
#
@@ -26,11 +27,10 @@ cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=viber
VERSION=${VERSION:-20.3.0.1}
-BUILD=${BUILD:-1}
+BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
-# 2023-05-16 DW: only 64bit supported
if [ -z "$ARCH" ]; then
ARCH=$( uname -m )
fi
@@ -40,14 +40,6 @@ if [ "$ARCH" != "x86_64" ]; then
exit 1
fi
-# 2023-05-16 DW: using this will mess up every tool known to man and SBo
-# Changed all to VERSION.
-# Get the real version
-#REAL_VER=$(ar p ${PRGNAM}.deb control.tar.xz | tar JxO ./control | grep Version | awk '{print $2}' | cut -d- -f1)
-
-# 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
-# could be useful to other scripts.
if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
exit 0
@@ -57,45 +49,31 @@ TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
-set -eu
+set -e
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $PKG
-ar p $CWD/${PRGNAM}.deb data.tar.xz | xz -d | tar xv
-# Move to standard place
-mv $PKG/opt/viber/* $PKG/usr/share/viber
-rm -r $PKG/opt
-# Fix desktop launcher
-sed -i 's/\/opt\/viber\/Viber/\/usr\/bin\/ViberPC/' $PKG/usr/share/applications/viber.desktop
-
-#
-# Make a shell launcher
-#
-# In my opinion, it's a bug... that is, Viber must be called from installation path
-# or with complete path to installation path, because it looks for other files.
-# Any symbolic link or hard copy of main binary to /usr/bin would yield a
-# non-working launcher.
-#
-# ViberPC is the name of the window (it is better to call it as such for a better
-# integration with docks, like cairo-dock)
-# Anyway for compatibility with previous version a link to /usr/bin/viber is created.
-#
-mkdir -p $PKG/usr/bin
-printf "#!/bin/sh\n/usr/share/viber/Viber\n" > $PKG/usr/bin/ViberPC
-ln -s ViberPC $PKG/usr/bin/viber
-
-# Adjust ownerships and permissions
+ar p $CWD/$PRGNAM.deb data.tar.xz | xz -d | tar xv
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 {} \;
-chmod +x $PKG/usr/bin/ViberPC
-cd
-# 2023-05-16 DW: this seems to work after stripping
+mkdir -p $PKG/usr/bin
+cd $PKG/usr/bin
+ln -s ../../opt/viber/Viber .
+
+# make libs executable
+find $PKG -name *.so -exec chmod 755 {} \;
+find $PKG -name *.so.* -exec chmod 755 {} \;
+
+# fix path
+sed -i 's:/opt/viber/::' $PKG/usr/share/applications/$PRGNAM.desktop
+sed -i 's:/usr/share/pixmaps/viber.png:viber:' $PKG/usr/share/applications/$PRGNAM.desktop
+
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
diff --git a/network/viber/viber.info b/network/viber/viber.info
index a0933f4fd205..bc103c977474 100644
--- a/network/viber/viber.info
+++ b/network/viber/viber.info
@@ -1,10 +1,10 @@
PRGNAM="viber"
VERSION="20.3.0.1"
-HOMEPAGE="https://www.viber.com/products/linux"
+HOMEPAGE="https://www.viber.com/"
DOWNLOAD="UNSUPPORTED"
MD5SUM=""
DOWNLOAD_x86_64="http://download.cdn.viber.com/cdn/desktop/Linux/viber.deb"
MD5SUM_x86_64="f9533157998f7f74b10d0dcd095c2b5d"
-REQUIRES="snappy"
-MAINTAINER="Roberto Metere"
-EMAIL="roberto@metere.it"
+REQUIRES="snappy tslib"
+MAINTAINER="Petar Petrov"
+EMAIL="slackalaxy@gmail.com"