diff options
author | Mario Preksavec <mario@slackware.hr> | 2015-02-03 07:01:34 +0100 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2015-02-07 15:21:05 +0700 |
commit | 85f9e83b73b39da6979138a782f558e76a6278f3 (patch) | |
tree | c6f757430f1e1d865938df2686ff0e16d155a05c /network/telegram/telegram.SlackBuild | |
parent | d407e40a38eeda7be2ebe23df5e7d177239e28e6 (diff) | |
download | slackbuilds-85f9e83b73b39da6979138a782f558e76a6278f3.tar.gz |
network/telegram: Updated for version 0.7.6 + enhancements
Diffstat (limited to 'network/telegram/telegram.SlackBuild')
-rw-r--r-- | network/telegram/telegram.SlackBuild | 54 |
1 files changed, 29 insertions, 25 deletions
diff --git a/network/telegram/telegram.SlackBuild b/network/telegram/telegram.SlackBuild index 020dc87f17..daf48613b2 100644 --- a/network/telegram/telegram.SlackBuild +++ b/network/telegram/telegram.SlackBuild @@ -22,45 +22,49 @@ # with this program (most likely, a file named COPYING). If not, see # <http://www.gnu.org/licenses/>. +# Modified by Mario Preksavec <mario@slackware.hr> + PRGNAM=telegram -VERSION=${VERSION:-0.6.15} +SRCNAM=tsetup +SRCDIR=Telegram +VERSION=${VERSION:-0.7.10} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} -if [ -z "$ARCH" ]; then - case "$( uname -m )" in - i?86) ARCH=i486 ;; - arm*) ARCH=arm ;; - *) ARCH=$( uname -m ) ;; - esac -fi +case "$( uname -m )" in + i?86) ARCH=i486 ;; + arm*) ARCH=arm ;; + *) ARCH=$( uname -m ) ;; +esac CWD=$(pwd) TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM OUTPUT=${OUTPUT:-/tmp} -TARBALL_x86="tsetup32.0.6.15.tar.xz" # Name of 32bit tarball -TARBALL_x86_64="tsetup.0.6.15.tar.xz" # Name of 64bit tarball -TARBALL_ROOT="Telegram" # Name of tarballs root directory - -# Set LIBDIRSUFFIX and TARBALL. -if [ "$ARCH" = "x86_64" ]; then - LIBDIRSUFFIX="64" - TARBALL="$TARBALL_x86_64" -else - LIBDIRSUFFIX="" - TARBALL="$TARBALL_x86" -fi - -set -eu +case "$ARCH" in + x86_64) + SRC="${SRCNAM}" + LIBDIRSUFFIX="64" + ;; + i486) + SRC="${SRCNAM}32" + LIBDIRSUFFIX="" + ;; + *) + echo "$ARCH is not supported." + exit 1 + ;; +esac + +set -e rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT cd $TMP -rm -rf "$TARBALL_ROOT" -tar xvf $CWD/$TARBALL -cd "$TARBALL_ROOT" +rm -rf $SRCDIR +tar xvf $CWD/$SRC.$VERSION.tar.xz +cd $SRCDIR chown -R root:root . find -L . \ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ |